Hello,
I have several comma-delimited lists that I'd like to INSERT into Oracle using PL/SQL. Each list has the same length, like this for example:
List 1 = 45, 'Joe', 'Smith', '123 Main St.';
List 2 = 46, 'Mary', 'Jones', '445 Maple St.';
List 3 = 47, 'Bill', 'Anderson', '443 Forest Lane';
List 4 = 48, 'Jane', 'Smith', '788 Wisteria Lane';
Is there a way for me to add these values into some sort of array, and then loop through them, and run an INSERT statement for each list?
I know I could just run an INSERT statement for each line, however, the procedure I'm running contains a lot more code for each insert, and I'm hoping that using an array of some sort will condense the code.
Thanks,
Peter![[smile] [smile] [smile]](/data/assets/smilies/smile.gif)
I have several comma-delimited lists that I'd like to INSERT into Oracle using PL/SQL. Each list has the same length, like this for example:
List 1 = 45, 'Joe', 'Smith', '123 Main St.';
List 2 = 46, 'Mary', 'Jones', '445 Maple St.';
List 3 = 47, 'Bill', 'Anderson', '443 Forest Lane';
List 4 = 48, 'Jane', 'Smith', '788 Wisteria Lane';
Is there a way for me to add these values into some sort of array, and then loop through them, and run an INSERT statement for each list?
I know I could just run an INSERT statement for each line, however, the procedure I'm running contains a lot more code for each insert, and I'm hoping that using an array of some sort will condense the code.
Thanks,
Peter
![[smile] [smile] [smile]](/data/assets/smilies/smile.gif)