Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Executing Oracle stored procedures
Message
From
05/09/2002 13:19:37
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Client/server
Title:
Executing Oracle stored procedures
Miscellaneous
Thread ID:
00697165
Message ID:
00697165
Views:
53
I have tried the following code in the click event of a foxpro7 button to execute a stored procedure in an Oracle database. I already have a connection and have cursor in VFP7 that displays to a grid but can not execute the stored procedure. What is wrong with this code?

* Make a connection to Oracle table (rissingg.employees)
* (execute delete_emp ) a stored procedure
STORE SQLCONNECT('Oracle_table','user_id','password') TO gnConnHandle
IF gnConnHandle <= 0
=MESSAGEBOX('Cannot make connection',16, 'SQL Connect Error')
ELSE
=MESSAGEBOX('Connection made',48,'SQL Connect Message')
ENDIF
=SQLPREPARE(gnConnHandle,'execute delete_emp')
=SQLEXEC(gnConnHandle)
=MESSAGEBOX('DELETE_EMP HAS RUN',48,'SQLEXEC Message')
** = SQLDISCONNECT(gnConnHandle) && save this line for use later
THISFORM.Refresh
Next
Reply
Map
View

Click here to load this message in the networking platform