Inserting records into MS-access (OpenInsight Specific)
At 17 SEP 2001 12:47:01AM Yogesh Kumar wrote:
I am able to make the connection and query from the query window.
I have also written OI stored procedure i.e. sql commands and able to retreive the records.
Now I want to write INsert/update/delete sql scripts in Stored procedure, could you please provide me sample stored procedure for it.
Thanks
Yogesh
At 17 SEP 2001 08:14AM James Birnie wrote:
Hi Yogesh
It sounds like you are are almost there. All ODBC drivers use SQL statements, which is good news as they are all pretty standard - eg. 'DELETE from STOCK' will remove ALL records, whereas 'DELETE from STOCK where STOCK_NO=T01"' (where STOCK_NO is the primary key) will remove just that row. You will need to understand how the different tables in your database relate to perform joins, as this integrity will be enforced.
If you can SELECT the records through OI you will be able to perform any other commands such as DELETE, UPDATE etc by simply exchanging the script. In terms of the actual syntax there would be heaps of examples on the web, just do a search for strings like SQL SYNTAX STATEMENTS…
Cheers,
James.