This section describes some programming considerations that you will need to keep in mind when writing Open Data Services routines that users will access as extended stored procedures in SQL Server (as opposed to routines that users will access on an Open Data Services server).
When standard stored procedures are added to SQL Server, an administrator defines their expected parameters so that the system can validate user-specified parameters and return syntax errors. With extended stored procedures, it is up to the application to validate any user-specified parameters.
When using the srv_senddone function to send a results completion message to the client, always set the completion status flag to SRV_DONE_MORE instead of to SRV_DONE_FINAL. The client receives SRV_DONE_FINAL from SQL Server.
Each extended stored procedure function that you create should follow these recommendations for accepting and responding to user input:
A single DLL file can contain multiple extended stored procedures. And SQL Server supports the use of multiple DLL files.