Lynn Pettis (5/9/2013)
Eugene Elutin (5/9/2013)
Lynn Pettis (5/8/2013)
Eugene Elutin (5/8/2013)
Actually you can, if you really want or need to!You should use cursor datatype in output parameter of your procedure. Here you will find a sample:
http://msdn.microsoft.com/en-GB/library/ms175498(v=sql.105).aspx
Should, also mention that this technique is not used very often...
Unless you are working with Oracle, then reference cursors are the only way to return data from a stored procedure.
😉
Sorry, what do you mean by that?
I know at least four ways of returning result(s) (data) from stored procedure in T-SQL.
Yes, T-SQL is nice in that way. I had the opportunity to work with Oracle for a year, and the methods we can use in T-SQL (MS SQL Server) don't work in Oracle. You use reference cursors to return data, which you can also use in T-SQL by returning a cursor as an outout parameter.
I'm not an Oracle expert, but I remember that it has few ways of getting back data too. Have you used pipelined functions?