This chapter introduces some advanced techniques for coding stored procedures, including:
Dynamically constructed queries
Parameterized queries
Methods for handling SQL Injection
Optimistic locking using timestamp values
Full-text searches and indexes
Nested stored procedures
Passing data to nested stored procedures using temporary tables and cursors
Inserting the results of a stored procedure into a table
Techniques for generating identity and unique identifier values and potential problems associated with their use
Additional looping methods