Jul
1
Written by:
Steve Gray
7/1/2011 7:55 AM
This works in SQL 2008 and doesn’t in SQL 2000, not sure about 2005
We all have to work with ‘black box’ applications sometime – the kind that has a database with tables and stored procedures that you can’t see into but you still have to work with it.
I had a case like that today, the parameters that I was sending to an encrypted stored procedure were not matching up. Usually that’s a versioning issue. Here’s a handy piece of code that will show you all the parameters in a stored procedure
- select PARAMETER_NAME, PARAMETER_MODE, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH,NUMERIC_PRECISION, NUMERIC_SCALE
- from INFORMATION_SCHEMA.PARAMETERS
- where SPECIFIC_NAME = 'taUpdateCreateCustomerRcd'
- order by ORDINAL_POSITION
As always, I welcome your comments!