November 20, 2002 at 8:31 am
From Query Analyser I have the following command:-
exec master..xp_cmdshell 'dtsrun -f "c:\dbtest\3RefExp1911.dts -n 3RefExp1911.dts' where 3RefExp1911.dts is a locally saved DTS Package
When I run this, all I get is the DTSrun options listed below as you would if you typed DTSrun /? in DOS. I have been using BCP which works fine but I can't seem to get it to export text fields in quotes, otherwise I would leave DTSRun alone. Any ideas please?
output
DTSRun Options ('/?' shows this screen; '-' May be substituted for '/'):
Package retrieval and contents:
/~S ServerName /~U UserName /~P Password /E <Use trusted connection instead
of /U /P>
/~N PackageName /~M PackagePassword /~G PackageGuidString /~V PackageVersion
GuidString
/~F Structured Storage UNC filename (overwritten if /S also specified)
/~R Repository Database Name <uses default if blank; loads package from Repo
sitory>
DTSRun action (default is to execute Package):
/!X <Do not execute; retrieves Package to /F filename>
/!D <Do not execute; drop package from SQL Server (cannot drop from Storage
File)>
/!Y <Do not execute; output encrypted command line>
/!C <Copies command line to Windows clipboard (may be used with /!Y and /!X)
>
Notes:
~ is optional; if present, the parameter is hex text of encrypted value (0x3
13233...)
Whitespace between command switch and value is optional
Embedded whitespace in values must be embedded in double-quotes
If an option is specified multiple times, the last one wins
November 20, 2002 at 9:42 am
Try this
exec master..xp_cmdshell 'dtsrun /fc:\dbtest\3RefExp1911.dts /n3RefExp1911'
instead of the syntax you have used and see if it works.
November 21, 2002 at 2:27 am
Brilliant - Thank you. Looking at my previous effort it seems it also failed because I had it on 2 lines which I didn't think mattered.
cheers
Paul
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply