Home » Other » General » sqlplus returning output values
sqlplus returning output values [message #257526] Wed, 08 August 2007 10:00 Go to next message
raj_23
Messages: 7
Registered: July 2007
Junior Member

    Set loShell = wscript.CreateObject("WScript.Shell")

        'Start populate the tables.
        lcsCommand = "sqlplus " & gmJobInfo("FaUserId") & "/" & gmJobInfo("ActualPassword") _
            & "@" & gmJobInfo("Datasource") & " @""" & lstrConfigDir & "Runstep1.ini"" " _
            & gmJobInfo("IsScheduled")
	
	WshShell.Run lcsCommand, 10, True



Above is an example.. I am running sqlplus from VBScript Shell..

Is there any way you can receive an output variable from the SQLPLUS to a VBScript variable...

(maybe stored proc o/p variable ?)
Re: sqlplus returning output values [message #257534 is a reply to message #257526] Wed, 08 August 2007 10:08 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Put a spool in your script and read the output file from VB.

Regards
Michel
Re: sqlplus returning output values [message #257796 is a reply to message #257534] Thu, 09 August 2007 03:22 Go to previous message
rleishman
Messages: 3728
Registered: October 2005
Location: Melbourne, Australia
Senior Member
Surely there is some way of integrating SQL with VB other than calling SQL*Plus. OCI or ODBC?

Calling an OS script is low-tech and prone to failure. It's just bad I.T.

Ross Leishman
Previous Topic: Need help with C libaries
Next Topic: How I Can Create Query >>> OO4O & VB
Goto Forum:
  


Current Time: Tue Nov 26 16:05:55 CST 2024