I'm working as DBA.I wish to do certifications for Microsoft sql server.So Could i know what are the certifications are available and what i've to do for certififcations.
Thanks in advance
David RPlease find all the details here.
I'm working as DBA.I wish to do certifications for Microsoft sql server.So Could i know what are the certifications are available and what i've to do for certififcations.
Thanks in advance
David RPlease find all the details here.
Try turning on tracing and view the logs. Also see event viewer if there are any issues. It could be an issue with the app or connectivity instead of Reporting Services, since the web service is used to service Report Manager.
More info on logging.
http://msdn2.microsoft.com/en-us/library/ms156500.aspx
cheers,
Andrew
|||Thank you Andrew for your prompt response. We will look at the logs and see if that leads us in the right direction.|||Some security patches were applied to the server in December. Is it possible that these could have messed with the way that authentication is handled?
Patches:
KB925398
KB925454
KB923689
KB911897
KB926247
KB923694
|||The app is getting the message back "The report server cannot open a connection to the report server database. A conection to the database is required for all requests and processing. SQL server does not exist or acess denied."|||Is it possible that any of these security patches could have messed with our authentication? Any suggestions Please.Hi,
Previously i was using oracle8i with ssis.ssis was working fine.later i have upgraded 8i to oracle 9i.now when ever i try to establish a new connection using Microsoft OLEDB Provider for Oracle.i am getting the following error "Oracle error occurred, but error message could not be retrieved from Oracle" .but i am able to access the oracle 9i database thru pl/sql and toad. what could be the problem?
Thanks
Jegan.T
We're running fine 9.2 on a development server (2005) along with SSIS packages.
What about tnsnames.ora?
|||Hi Enric,
my tnsnames.ora is correct .bcoz i am able to login via toad/sqlplus.while upgradeing i have unistalled 8i and installed 9i . do we need to install any drivers?
Thanks
Jegan.T
I need some help in the worst way. I had a program/database I was working on a particular machine. I took all the data from there and placed it on a another machine. Now I'm unable to navigate through the web pages on the new machine. I am getting the error...
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.
......asp, line 19
Can you please help!!
Quote:
Originally Posted by ConfusedDeuce
Hello Group,
I need some help in the worst way. I had a program/database I was working on a particular machine. I took all the data from there and placed it on a another machine. Now I'm unable to navigate through the web pages on the new machine. I am getting the error...
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.
......asp, line 19
Can you please help!!
Quote:
Originally Posted by ConfusedDeuce
Hello Group,
I need some help in the worst way. I had a program/database I was working on a particular machine. I took all the data from there and placed it on a another machine. Now I'm unable to navigate through the web pages on the new machine. I am getting the error...
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.
......asp, line 19
Can you please help!!
Quote:
Originally Posted by Motoma
On line 19, your connection to the database is failing. Are you on the same network segment/subnet as you previously were? What is the physical difference between the computers?
Quote:
Originally Posted by r035198x
How are you now specifying the server name when connecting to this machine?
You'll need to allow the server port on that new machine if it's running a firewall.
Quote:
Originally Posted by ConfusedDeuce
The thing is that I'm not completely sure what the other machine had on it because they data was copied over from that machine and the machine was immediately taken away. Now I am using VMWare and virtually connected to new machine (which shouldnt be the problem). I'm not sure of any of the specs of the last machine : (
Quote:
Originally Posted by Motoma
Do you have the SQL Server database up and running on the new machine? Have you added the appropriate accounts and permissions for the users?
Quote:
Originally Posted by ConfusedDeuce
Yes it is up and running. How do i add the accounts and permissions?
Quote:
Originally Posted by ConfusedDeuce
I'm not connecting to the old machine anymore. That machine is out of the office and no longer in physical reach.
Hello there,
I'm working with Analysis sevices 2005 developer edition. Looking through the documentation i becomes apperent that the NN algorithm takes 255 input attributes by default. This can be changed to any integer value, OK....
My problem is that I want to feed the network with 40000 input variables. In order to do so, I will have to do a select:
SELECT fld1, fld2, ...... fld39999, fld40000
FROM tblSometable
However, this is not possible, as the books online describes it is only possible to return 4096 columns from a select statement.
Question : How do I populate a NN in AS2005, with nmore than 4096 inputs ?!
The limit may actually be smaller. SQL Server supports, I think, only 1024 columns
Analysis Services 2005 supports the concept of nested table which allows multiple related tables to be included in modeling.
With nested tables, Analysis Services can use much larger input sets (even hundreds of thousands) represented in multiple tables. Some details on the nested table concept are available here. http://msdn2.microsoft.com/en-us/library/ms175659.aspx
However, this is a data modeling issue and not related to the NN 255 default limit.
The NN algorithm (and many other algorithms included in SQL Server 2005) will always perform feature selection,using (by default) 255 input attributes. it means that, even when your data contains 40K inputs, NN will still use, by default, only the most significant 255. To increase this limit, change the value of the MAXIMUM_INPUT_ATTRIBUTES algorithm parameter. This parameter has the same name for all the algorithms that perform feature selection. If you cange this parameter value to, say, 40000, then all 40K inputs will be used.
|||
Thanks.
I suspected I could do this using nested tables. Thanks for confirming this. Time might be an issue, however. Mu current test-network consisting of 1000 inputs (MAX_INPUT_ATTRIB = 1000), that are zeros and ones, takes +3 hours on a 3.0Ghz PentiumD with 3 GB om memory. Is the time going to grow exponential or linear with the number of input nodes ?
regs,
Mads
Hello there,
I'm working with Analysis sevices 2005 developer edition. Looking through the documentation i becomes apperent that the NN algorithm takes 255 input attributes by default. This can be changed to any integer value, OK....
My problem is that I want to feed the network with 40000 input variables. In order to do so, I will have to do a select:
SELECT fld1, fld2, ...... fld39999, fld40000
FROM tblSometable
However, this is not possible, as the books online describes it is only possible to return 4096 columns from a select statement.
Question : How do I populate a NN in AS2005, with nmore than 4096 inputs ?!
The limit may actually be smaller. SQL Server supports, I think, only 1024 columns
Analysis Services 2005 supports the concept of nested table which allows multiple related tables to be included in modeling.
With nested tables, Analysis Services can use much larger input sets (even hundreds of thousands) represented in multiple tables. Some details on the nested table concept are available here. http://msdn2.microsoft.com/en-us/library/ms175659.aspx
However, this is a data modeling issue and not related to the NN 255 default limit.
The NN algorithm (and many other algorithms included in SQL Server 2005) will always perform feature selection,using (by default) 255 input attributes. it means that, even when your data contains 40K inputs, NN will still use, by default, only the most significant 255. To increase this limit, change the value of the MAXIMUM_INPUT_ATTRIBUTES algorithm parameter. This parameter has the same name for all the algorithms that perform feature selection. If you cange this parameter value to, say, 40000, then all 40K inputs will be used.
|||
Thanks.
I suspected I could do this using nested tables. Thanks for confirming this. Time might be an issue, however. Mu current test-network consisting of 1000 inputs (MAX_INPUT_ATTRIB = 1000), that are zeros and ones, takes +3 hours on a 3.0Ghz PentiumD with 3 GB om memory. Is the time going to grow exponential or linear with the number of input nodes ?
regs,
Mads
quote:
> I am working on a project that needs to retrieve the metadata details of a
quote:
> Could anyone help me out..
> TIA,
> Arrun
I recently restored my database from a backup and it seems that something in my service broker setup has stopped working, no messages now appear.
I checked that the broker was enabled (it wasnt and i had to use NEW_BROKER because of the 'same id' message)
The database is still set to trustyworthy.
There are also no messages in sys.transmission_queue
I used profiler with all the broker events enabled and the result was as follows:
Broker:Conversation Group
Broker:Conversation STARTED_OUTBOUND
Broker:Conversation CONVERSING
Broker:Message Classify
Broker:Conversation CLOSED
Broker:Conversation Group
Broker:Message Classify
But i'm not sure whether this highlights a problem or not? Any help gratefully appreciated!!
Thanks,
Andy
Hi,
I had the complete conversation - including the end of the conversation - in a stored procedure.
This was the reason i wasn't getting anything in sys.transmission_queue - i didnt end the conversation and the error appeared.
It turned out to be a permissions thing as when i'd restored the database it had set the owner to [SA]
Sorry for wasting your time if you'd bothered to read my problem!
Cheers,
Andy
I recently restored my database from a backup and it seems that something in my service broker setup has stopped working, no messages now appear.
I checked that the broker was enabled (it wasnt and i had to use NEW_BROKER because of the 'same id' message)
The database is still set to trustyworthy.
There are also no messages in sys.transmission_queue
I used profiler with all the broker events enabled and the result was as follows:
Broker:Conversation Group
Broker:Conversation STARTED_OUTBOUND
Broker:Conversation CONVERSING
Broker:Message Classify
Broker:Conversation CLOSED
Broker:Conversation Group
Broker:Message Classify
But i'm not sure whether this highlights a problem or not? Any help gratefully appreciated!!
Thanks,
Andy
Hi,
I had the complete conversation - including the end of the conversation - in a stored procedure.
This was the reason i wasn't getting anything in sys.transmission_queue - i didnt end the conversation and the error appeared.
It turned out to be a permissions thing as when i'd restored the database it had set the owner to [SA]
Sorry for wasting your time if you'd bothered to read my problem!
Cheers,
Andy
Hi...
My service broker was working...all of a sudden it stopped working...so i figured out destination queue was disabled and I set it as
ALTER QUEUE SERVERQUEUE
WITH STATUS = ON, RETENTION = ON, ACTIVATION (
STATUS = ON, PROCEDURE_NAME = usp_OnReceiveMessage,
MAX_QUEUE_READERS = 5, EXECUTE AS OWNER )
Also altered my database for trustworthy after going through some posts previously.
Now the message is sent...i dont see any message in my tranmission queue but i dont receive the message in destination server.
When i checked endpoints...select * from sys.conversation_endpoints I see the last message with st_desc as conversing...
how do I solve this...?
Thanks,
Pramod
The queue must have been disabled because you must have rolled back a transaction that performed a RECEIVE on the queue 5 or more times consecutively. Read about poised message handling here.
If the message is neither in transmission queue nor in the destination queue, chances are that the dialog was errored. Look in the initiator queue as well. I don't get what you mean by "the last message" in sys.conversation_endpoints. The conversation endpoints view does not contain any messages. The st_desc column describes the state of the conversation endpoint.
|||Rushi:
I reconfigured the service broker...this time...in transmission queue its showing this error....
Connection handshake failed. The certificate used by the peer is invalid due to the following reason: The database principal has no mapping to a server principal.
State 89.
What does this mean ?
Thanks,
|||
You are using certificates for adjacent (i.e. transport) security. The certificate used by the peer belongs to a user in master who is not mapped to a login. This could happen either because:
i) You created a user in master without login.
ii) You created a user in master with a login, but later dropped that login, thus orphaning that user.
The fix would be to create a SQL login, then create a user in master for this login and alter authorization of the peers certificate to be owned by this user. Next grant connection permission on the service broker endpoint to the newly created login.
Hope that helps.
|||Rushi:
I want to confirm few things here...before proceeding...
Lets take a login sbuser(created to login with sql authentication). This is the login i would be using to create endpoints, certificates, service etc for server service broker.
Should I have to login as sa to create those or I am fine with sbuser ?
Next step...in master database I create a user lets say proxysbuser which will be used to connect endpoints on both sides ie.initiator and target service brokers.
Then I i use proxysbuser to alter authorization of the peers certificate.
Am I in the right track ? Let me know.
Thanks,
Pramod
|||Configuring dialog security (i.e. between services) is independent of configuring adjacent security (i.e. between instances) and should not be confused. For configuring adjacent security the steps are as follows:
1> Instance A: Create certificate owned by the dbo of master.
2> Instance A: Create SSB endpoint using the above certificate for authentication.
3> Instance A: Export certificate to \\shared\A.crt
4> Instance B: Create certificate owned by the dbo of master.
5> Instance B: Create SSB endpoint using the above certificate for authentication.
6> Instance B: Export certificate to \\shared\B.crt
7> Instance A: Create login for instance B, let's say InstanceB.
8> Instance A: Create user in master for login InstanceB.
9> Instance A: Import certificate \\shared\B.crt into master with owner InstanceB.
10> Instance A: Grant connect permission on SSB endpoint to login InstanceB.
11> Instance B: Create login for instance A, let's say InstanceA.
12> Instance B: Create user in master for login InstanceA.
13> Instance B: Import certificate \\shared\A.crt into master with owner InstanceA.
14> Instance B: Grant connect permission on SSB endpoint to login InstanceA.
The steps for securing dialogs are different from this. Refer to the docs for that.
If you find this tedious, you can use Remus' Service Listings Manager which automates this process for you.
Rushi
|||Rushi:
I have been trying to use Remus Service Listing I have been refering to this link...https://blogs.msdn.com/remusrusanu/archive/2006/04/07/571066.aspx
In this step The administrator of the SQL Server instance hosting service ‘A’
In import mode the created script throws this error....
Msg 6522, Level 16, State 1, Procedure ssb_create_certificate_from_blob, Line 0 A .NET Framework error occurred during execution of user defined routine or aggregate 'ssb_create_certificate_from_blob': System.Data.SqlClient.SqlException: A certificate with name 'COSCOSB' already exists or this certificate already has been added to the database.
System.Data.SqlClient.SqlException:
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnectionSmi.EventSink.ProcessMessagesAndThrow(Boolean ignoreNonFatalMessages)
at Microsoft.SqlServer.Server.SmiEventSink_Default.ProcessMessagesAndThrow(Boolean ignoreNonFatalMessages)
at System.Data.SqlClient.SqlCommand.RunExecuteNonQuerySmi(Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at Microsoft.SqlServiceBroker.Samples.CertificatesBlob.CertificatesBlob.ssb_create_certificate_from_blob(SqlString databaseName, SqlString certificateName, SqlString authorizationUser, SqlBinary certificateBody)
The script which is throwing error is IF EXISTS(SELECT * FROM sys.certificates WHERE name = 'COSCOSB')
DROP CERTIFICATE [COSCOSB];
declare @.dbname sysname;
select @.dbname = DB_NAME();
print @.dbname -- this prints master
exec msdb.dbo.ssb_create_certificate_from_blob @.dbname, 'COSCOSB','COSCOSB',0x308201ED30820156A00302010202104B7566A1DEA72E844040F300FC947B6C300D06092A864886F70D010105050030353133303106035504031E2A0043004F00530043004F005F00430045005200540049004600490043004100540045005F005300550042301E170D3036303832373030303030305A170D3037303832383030303030305A30353133303106035504031E2A0043004F00530043004F005F00430045005200540049004600490043004100540045005F00530055004230819F300D06092A864886F70D010101050003818D0030818902818100D5DDA3F09C737A7F39E9E262C6B6C62524C3C8368750DC014AEE582FCDF97E29760C0452513414520FD8DB0A8CD3A389E15D0C5C5B006228145E405ADC2344ABF0DC08BF7647BEE413525C5E29B39107424479D70F25CD32F4FB95B43974E785C81410EF506EEC59E2C6CC6135F009300F5B496FF837E50AF8EB02F806CA99870203010001300D06092A864886F70D01010505000381810038C506E25FB74C59D08C58E56D9ED505A01AE0C33E5F28E5135D9E492F5E6B33703550E14042FF87EE83E8F8C43522EAEE9EDA417E7178BFB8BF7B5B27EA05926D4C52C9CAE9B7915A890422FCE67A4ED473E29154E1205A3CAF3245B0477A469192D409A0C5EB52BC307217CF7CA3C675F7305FC11503ECA17503EB1B493A4D;
GO
I dont have any certifcate in sys.certificates....why is it throwing error ? Could you pls tell me.
Thanks,
Pramod
.
|||I think this is a known bug. I'm not sure if Remus has fixed it yet. You can try using the latest version and see if that works. Presently, Remus is on vacation, but I'll ask him to follow up on this bug when he gets back.
In the mean time, look at sys.certificates for any other certificate which may have been created (possibly with a different name).
Rushi
|||Rushi:
Thanks for quick response...but I am sure i am using the latest version Service Lsiting Manager v1.1.3 which says that bug is fixed...sys.certifcates is empty. But will keep working on it.
Thanks,
Pramod
|||Are you in the right database?|||Yup....I am in master....
|||Rushi...my client db is standard sql2005 and server is developer sql2005 do u think that might be causing problem ?
|||No. The error is unrelated to licensing.|||On the correct instance? Service Listing Manager is simply running the SELECT * FROM sys.certificates query and finding a certificate but you are not.|||
Rushi:
Service Listing Manager is working fine in developer edition...I tried with 2 instances of standard edition on 2 different m/c it fails at this step exec msdb.dbo.ssb_create_certificate_from_blob @.dbname .......
i am working on storedprocedures and after the Succesful parsing of the procedure .. on executing its giving me 3 msgs ....
Configuration option 'show advanced options' changed from 0 to 1. Run the RECONFIGURE statement to install.
Configuration option 'xp_cmdshell' changed from 1 to 1. Run the RECONFIGURE statement to install.
Configuration option 'show advanced options' changed from 1 to 0. Run the RECONFIGURE statement to install.
and not displaying me the output.......
The Procedure i am executing is as follows
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
go
CREATE PROCEDURE [dbo].[uspRcopiaExport12] AS
DROP TABLE Skagway..RCOPIA_EXPORT
-- Get Patients' Home Addresses
/*
SELECT pa.PersonID, pa.Street1, pa.Street2, pa.City, pa.State, Skagway.dbo.StripNonDigits(pa.ZipCode) AS Zip
INTO #ADDRESS
FROM Person..PHYSICAL_ADDRESS pa
INNER JOIN Person..PHYSICAL_ADDRESS_DESC pad ON (pa.PhysicalAddrDescID = pad.PhysicalAddrDescID)
WHERE pad.PhysicalAddrDesc = 'Home'
-- Get Patients' Home Phone Numbers
SELECT tn.PersonID, tn.TelecomNumber
INTO #HOME_PHONE
FROM Person..TELECOM_NUMBER tn
INNER JOIN Person..TELECOM_NUMBER_DESC tnd ON (tn.TelecomNumDescID = tnd.TelecomNumDescID)
INNER JOIN Person..TELECOM_DEVICE_TYPE tdt ON (tn.TelecomDevTypeID = tdt.TelecomDevTypeID)
WHERE tnd.TelecomNumDesc = 'Home'
ORDER BY tdt.TelecomDevTypeID
-- Get Patients' Work Phone Numbers
SELECT tn.PersonID, tn.TelecomNumber
INTO #WORK_PHONE
FROM Person..TELECOM_NUMBER tn
INNER JOIN Person..TELECOM_NUMBER_DESC tnd ON (tn.TelecomNumDescID = tnd.TelecomNumDescID)
INNER JOIN Person..TELECOM_DEVICE_TYPE tdt ON (tn.TelecomDevTypeID = tdt.TelecomDevTypeID)
WHERE tnd.TelecomNumDesc = 'Work'
ORDER BY tdt.TelecomDevTypeID
*/
-- Get SCP patient demographic data
SELECT 'update_patient_4' AS DataType,
p.FirstName AS FIRST_NAME,
p.MiddleInit AS MIDDLE_INITIAL,
p.LastName AS LAST_NAME,
CASE p.Gender
WHEN 'm' THEN 'M'
WHEN 'f' THEN 'F'
WHEN 'M' THEN 'M'
WHEN 'F' THEN 'F'
ELSE 'U'
END AS SEX,
-- (SELECT TOP 1 Street1 FROM #ADDRESS WHERE PersonID = p.PersonID) AS ADDRESS_LINE_1,
-- (SELECT TOP 1 Street2 FROM #ADDRESS WHERE PersonID = p.PersonID) AS ADDRESS_LINE_2,
-- (SELECT TOP 1 City FROM #ADDRESS WHERE PersonID = p.PersonID) AS CITY,
-- (SELECT TOP 1 State FROM #ADDRESS WHERE PersonID = p.PersonID) AS STATE_CODE,
-- (SELECT TOP 1 Zip FROM #ADDRESS WHERE PersonID = p.PersonID) AS ZIP,
-- (SELECT TOP 1 TelecomNumber FROM #HOME_PHONE WHERE PersonID = p.PersonID) AS PHONE,
-- (SELECT TOP 1 TelecomNumber FROM #WORK_PHONE WHERE PersonID = p.PersonID) AS WORK_PHONE,
' 'AS ADDRESS_LINE_1,
' 'AS ADDRESS_LINE_2,
' 'AS CITY,
' 'AS STATE_CODE,
' 'AS ZIP,
' 'AS PHONE,
' 'AS WORK_PHONE,
' ' AS OTHER_PHONE,
-- ea.EmailAddress AS EMAIL,
' ' AS EMAIL,
p.BirthDate AS BIRTHDATE,
p.SocSecNum AS SOCIAL_SECURITY,
' ' AS INSURANCE,
' ' AS LAST_VISIT_DATE,
'PHMS-SCP-' + CAST(p.PersonID AS VARCHAR(8)) AS EXTERNAL_ID,
' ' AS PROVIDER_FIRST_NAME,
' ' AS PROVIDER_MIDDLE_NAME,
' ' AS PROVIDER_LAST_NAME
INTO Skagway..RCOPIA_EXPORT
FROM Skagway..PERSON p
INNER JOIN Skagway..EMAIL_ADDRESS ea ON (p.PersonID=ea.PersonID)
INNER JOIN Skagway..CARE_TEAM_ASSIGNMENT cta ON (p.PersonID=cta.PersonID)
INNER JOIN Skagway..SHARED_CARE_PLAN scp ON (cta.CarePlanID=scp.CarePlanID)
WHERE scp.SCPInactiveFlag <> 1
AND cta.CareTeamRoleID = 23
AND p.BirthDate IS NOT NULL
AND p.SocSecNum IS NOT NULL
AND NOT p.SocSecNum IN ('999999999', '')
-- Replace all NULLs with single spaces (required by Rcopia for import)
UPDATE Skagway..RCOPIA_EXPORT
SET MIDDLE_INITIAL = ' '
WHERE MIDDLE_INITIAL IS NULL OR MIDDLE_INITIAL = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET PHONE = ' '
-- WHERE PHONE IS NULL OR PHONE = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET WORK_PHONE = ' '
-- WHERE WORK_PHONE IS NULL OR WORK_PHONE = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET ADDRESS_LINE_1 = ' '
-- WHERE ADDRESS_LINE_1 IS NULL OR ADDRESS_LINE_1 = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET ADDRESS_LINE_2 = ' '
-- WHERE ADDRESS_LINE_2 IS NULL OR ADDRESS_LINE_2 = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET CITY = ' '
-- WHERE CITY IS NULL OR CITY = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET STATE_CODE = ' '
-- WHERE STATE_CODE IS NULL OR STATE_CODE = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET ZIP = ' '
-- WHERE ZIP IS NULL OR ZIP = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET EMAIL = ' '
-- WHERE EMAIL IS NULL OR EMAIL = ''
--UPDATE Skagway..RCOPIA_EXPORT
-- SET SOCIAL_SECURITY = ' '
-- WHERE SOCIAL_SECURITY IS NULL OR SOCIAL_SECURITY = ''
-- Create the pipe-delimited ascii file on the HiNet server
DECLARE @.cmd varchar(1000)
--DECLARE @.pwd varchar(30)
--SELECT @.pwd = (SELECT Password FROM master..Passwords WHERE UserName = 'DBO_HelpDesk')
DECLARE @.FileName varchar(100)
--SET @.FileName = '"\\phins\d$\scppatients.txt"' -- Can't get to HiNet at the moment, create it on PHINS
-- SET @.FileName = '"\\x.xx.x.x\phms\phmspatients.txt"'
SET @.FileName = '"C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\LOG\1.txt"'
--SELECT @.cmd = 'master..xp_cmdshell ' + char(39) + 'bcp Skagway..RCOPIA_EXPORT out ' + @.FileName + ' -c -t"|" -UDBO_HelpDesk -P' + @.pwd + ' -S' + @.@.SERVERNAME + char(39)
SELECT @.cmd = 'master..xp_cmdshell ' + char(39) + 'bcp Skagway..RCOPIA_EXPORT out ' + @.FileName + ' -c -t"|" -T -S' + @.@.SERVERNAME + char(39)
EXEC (@.cmd)
--DROP TABLE #ADDRESS
--DROP TABLE #HOME_PHONE
--DROP TABLE #WORK_PHONE
-
The Query i am executing after this is
USE master
GO
EXEC sp_configure 'show advanced options', 1
GO
RECONFIGURE WITH OVERRIDE
GO
EXEC sp_configure 'xp_cmdshell', 1
GO
RECONFIGURE WITH OVERRIDE
GO
EXEC sp_configure 'show advanced options', 0
GO
and the output i m looking for is like this ......
-- <Fst name><mid name><lst name> < DOB><SSN> <ID>
update_patient_4|Dawn|M|Gauthier|F| | | | | | | | | |08/30/1974|370845156| | |SCP-2| | |
update_patient_4|Keith| |Robinson|M| | | | | | | | | |09/28/1948|537523557| | |SCP-9| | |
I moved this thread from SSIS forum; I think the T-SQL one is a better place for this