February 1, 2008 at 8:37 am
Hi Guys,
We are using MSSQL Server 2000 and Sybase PowerBuilder. I need to know if it is possible to call a Powerbuilder exe through a SQL Server Stored procedure.
I would appreciate your help.
Thanks
February 1, 2008 at 8:40 am
provided the app doesn't need any user intervention and message boxes etc can be suppressed then you can call an executable from SQL stored proc by using xp_cmdshell to shell out to the OS. It's crude but it works.
HTH
thanks
SQL_EXPAT
February 1, 2008 at 8:46 am
Is it possible to get an example.
Thanks
February 1, 2008 at 9:30 am
exec xp_cmdshell 'dir c:\'
February 3, 2008 at 12:48 pm
February 3, 2008 at 4:13 pm
You could also (shudder) create a COM object for your powerbuilder code and use the sp_OAxxx procedures in MS SQL to call your code. It depends if you want to pass parameters around the place or if you're happy building a command line (with any parameters appropriately escaped) and then parsing the recordset from xp_cmdshell...
February 3, 2008 at 7:05 pm
We are a PowerBuilder & SQL Server shop. We have a sister company that develops for handhelds.
I have to develop this procedure for them. They will call this procedure and then I will call a PB exe already in use.
Hope this helps.
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply