Re: FTPing and Calling an EXE from a SQL Statement
From: Dan Guzman (guzmanda_at_nospam-online.sbcglobal.net)
Date: 01/22/05
- Next message: oj: "Re: sql server automatic update error"
- Previous message: Dan Guzman: "Re: Clustered and non-clustered index"
- In reply to: Chris Hayes: "FTPing and Calling an EXE from a SQL Statement"
- Next in thread: Chris Hayes: "Re: FTPing and Calling an EXE from a SQL Statement"
- Reply: Chris Hayes: "Re: FTPing and Calling an EXE from a SQL Statement"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 21 Jan 2005 23:28:44 -0600
I don't have links handy on this specific requirement, but one method is to
execute the needed FTP command (perhaps with the -s parameter) via
xp_cmdshell. You can find more info on accomplishing this securely at
http://www.winnetmag.com/Article/ArticleID/25145/25145.html. This article
was written before SQL 2000 SP3. If your are running SQL 2000 SP3+, your
user database needs to be owned by 'sa' and you need to enable the 'db
chaining' database option in your user database in order to maintain an
unbroken ownership chain to xp_cmdshell.
Note that you should enable the 'db chaining' option in sa-owned user
databases when only sysadin role members have permissions to create
dbo-owned objects in that database.
-- Hope this helps. Dan Guzman SQL Server MVP "Chris Hayes" <cp.hayesATsbcglobal.net@nospam.nospam> wrote in message news:e3i0aTCAFHA.3592@TK2MSFTNGP09.phx.gbl... > Greetings, > > I've seen this done in other places...I wish I had paid better attention > because I can't remember how it was all done. > > But can someone point me the resources to accomplish my stated desires to > FTP a file from within a SQL Statement and also to run an .EXE from within > a SQL Statement... > > Thanks, > > Chris > > > >
- Next message: oj: "Re: sql server automatic update error"
- Previous message: Dan Guzman: "Re: Clustered and non-clustered index"
- In reply to: Chris Hayes: "FTPing and Calling an EXE from a SQL Statement"
- Next in thread: Chris Hayes: "Re: FTPing and Calling an EXE from a SQL Statement"
- Reply: Chris Hayes: "Re: FTPing and Calling an EXE from a SQL Statement"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|