On Sat, Mar 7, 2009 at 5:37 AM, PJ <af.gour...@videotron.ca> wrote:

> I've done some rethingking and this may be the direction to go:
>
> What I need to wind up with is something like this:
>
> $sql = "INSERT INTO book_categories ( book_id, category )
>     VALUES( '$autoID', '$categoriesID[0]' ),
>    ( '$autoID', '$categoriesID[1]' ),
>    ( '$autoID', '$categoriesID[2]' ),
>    ( '$autoID', '$categoriesID[3]' )
>    ( '$autoID', '$categoriesID[4]' )";
>
> Does it make sense?
> How do I pass the values to the query?
>
>
>
> You can run a php loop inside the insert  clause.
But if its already existing record then it woud be UPDATE clause.

Reply via email to