Seperate out your query string into a variable and do it like this:
$query = "select a,b,c,d from table sometable "
. " where something=somevalue and "
. " otherstuff = 'bbb' ";
if (!$results=mysql_query($query)) die (mysql_error());
----- Original Message -----
From: "WCBaker" <[EMAIL PROTECTED]>
To: "MySQL" <[EMAIL PROTECTED]>
Sent: Saturday, February 24, 2001 5:02 PM
Subject: silly question but I'm stumped
> Hi All!
>
> I have a need to make a LONG insert command. Does anyone have an example
> of something like this:
> $result1=MYSQL_QUERY("INSERT INTO test(dataA,dataB) VALUES
> ('$dataA','$dataB')");
>
> but SPREAD over more than one line? I can't seem to get the quotes and
> backslashes right for some unknown reason, although it ought to be
straight
> forward (and I'm sure it is - I've done it with other commands. . .).
>
> Thanks if anyone can help.
>
> Cheers!
>
> -Warren
>
>
> ---------------------------------------------------------------------
> Before posting, please check:
> http://www.mysql.com/manual.php (the manual)
> http://lists.mysql.com/ (the list archive)
>
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail
<[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
>
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php