In case that it might be useful to someone
passing parameters to an MSSQL storedprocedure and getting the results

  // MSSQL (microsoft sql server) from 4D ( appears to work in compiled and 
interpreted mode )
  // this runs server side which is a windows device, though could work on any 
device that also has the ODBC defined below connection
  // if run serverside and need data back at client device you can execute on 
server and use GET PROCESS VARIABLE to get the serverside results
  // User at your own discretion, not evaluated for security considerations.
  
ARRAY TEXT(aTEXT1;0)
ARRAY TEXT(aTEXT2;0)
ARRAY TEXT(aTEXT3;0)
SQL LOGIN("ODBC:myODBCnams";"sqluser";"sqlpassword!";*)  //this is the ODBC 
setup (windows OS)
SQL SET PARAMETER($in;SQL param in)
  //this stored procedure returns a dataset with three varchar columns
SQL EXECUTE("exec MYSTOREDPROCEDURE ?";aTEXT1;aTEXT2;aTEXT3)
SQL LOAD RECORD(SQL all records)
SQL LOGOUT

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to