OK, I think I see where you are coming from.
I was originaly going to send the detail as three seperate variables, i.e.
@code - '1,344,8877,3,144...'
@date1 - '01/01/03,02/01/03,03/06/04...'
@date2 - '10/02/03,02/04/03,25/07/03...'
From what I can understand of your code you are saying that...