Addressed to: Clayton Dukes <[EMAIL PROTECTED]>
              [EMAIL PROTECTED]

** Reply to note from Philip Olson <[EMAIL PROTECTED]> Sat, 24 Feb 2001 01:31:30 
+0000 (GMT)
>
>
> > Hello, This is my first attempt, so I'm prolly doing something stupid,
> > but can someone tell me why this doesn't work? All it returns is
> > "Unable to INSERT to database"
>
> Change : or die("Unable to INSERT to database");
> To     : or die(mysql_error());
>
> And see what it tells you.  Odds are there's a field not being accounted
> for.  When not designating columns (just values) it's important to make
> sure all columns are accounted for.  See :
>
>     http://www.sqlcourse.com/
>
> It'll provide some basic SQL help.  It's recommended to write out columns
> and values (easier to make sense of).

I find SET even easier:


   INSERT INTO Table SET

or

   UPDATE Table SET


then

      field1 = '$Field1',
      field2 = '$Field2',
      fieldN = '$FieldN'


That makes it very easy to keep track of what goes where.  It is
somewhat new to MySQL, but anything less than a year old should have it
available.




Rick Widmer
Internet Marketing Specialists
http://www.developersdesk.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to