Re: Passing arrays to a stored procedure
From: Joe Celko (jcelko212_at_earthlink.net)
Date: 11/19/04
- Next message: Daniell: "Remove ending characters"
- Previous message: David Gugick: "Re: Need to catch up on stored procedures"
- In reply to: Preeta: "Passing arrays to a stored procedure"
- Next in thread: louise raisbeck: "Re: Passing arrays to a stored procedure"
- Reply: louise raisbeck: "Re: Passing arrays to a stored procedure"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 19 Nov 2004 10:20:58 -0800
>> Can you pass arrays to a stored procedure? if so, how? Please
explain. <<
You reallllllly need to get a book on the basics before you try to
program in the language.
SQL uses tables as its only data structure and it holds only scalar
(atomic) values. There are no arrays in the language. Parameters are
scalars. You will need to break the the host language array elements
into scalars.
There are several kludges for this kind of bad programming available in
FAQ. However, the right answer is to learn to think and write proper
SQL code instead of trying to force your old mental model of data into
SQL.
--CELKO--
Please post DDL, so that people do not have to guess what the keys,
constraints, Declarative Referential Integrity, datatypes, etc. in your
schema are. Sample data is also a good idea, along with clear
specifications.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
- Next message: Daniell: "Remove ending characters"
- Previous message: David Gugick: "Re: Need to catch up on stored procedures"
- In reply to: Preeta: "Passing arrays to a stored procedure"
- Next in thread: louise raisbeck: "Re: Passing arrays to a stored procedure"
- Reply: louise raisbeck: "Re: Passing arrays to a stored procedure"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|