List:General Discussion« Previous MessageNext Message »
From:Chris Date:July 17 2006 8:01am
Subject:Re: arrays in stored procedures - pl. help
View as plain text  
L P wrote:
> Folks,
> say I have a need to add multiple rows at the same time.
> 
> for instance, say I'm collecting customer information and I want to add 3
> addresses and 3 phone numbers at the same time for a customer.
> 
> The above is quite straightforward to accomplish when there is only one set
> of data to deal with (one address / one phone number) - with simple data
> types passed in as parameters.
> 
> What alternatives / options do I have to accomplish storing multiple 
> sets of
> data?

insert into table(field1, field2, field3) values (value1, value2, 
value3), (value4, value5, value6);

http://dev.mysql.com/doc/refman/5.1/en/insert.html

Don't use arrays for storage, you'll lose a lot of performance.

Thread
arrays in stored procedures - pl. helpL P16 Jul
  • Re: arrays in stored procedures - pl. helpChris17 Jul
    • Re: arrays in stored procedures - pl. helpL P26 Jul
      • Re: arrays in stored procedures - pl. helpPeter Brawley26 Jul