Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Pass a web variable to a stored procedure
Message
 
 
To
29/01/2008 14:34:46
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
01257541
Message ID:
01286876
Views:
34
>>Can you create a SP in your database that would return the inserted value (GETAUTOINC()) and try to execute this SP instead of the direct insert?
>
>Probably, that's what Cetin recommended. But wouldn't know how to return the value to ASP.

Found some sample
Set cn = Server.CreateObject("ADODB.Connection")
   Set rs = server.createobject("ADODB.recordset")
   cn.Open "data source name", "userid", "password"
   Set cmd = Server.CreateObject("ADODB.Command")
   Set cmd.ActiveConnection = cn
   cmd.CommandText = "spMyCalc"
   cmd.CommandType = adCmdStoredProc
   cmd.Parameters.Append cmd.CreateParameter("intUnitID", adInteger, _
      adParamReturnValue)
   ' Set value of intUnitID of the default collection to 22 (or whatever)
   cmd("intUnitID") = 22
   rs = cmd.Execute
at http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/ASP/Q_22656893.html
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform