RE: [PHP-DB] possible Error in Querydefiniton
| From: | John W. Holmes | Date: | Mon, 07 Oct 2002 09:15:33 +0000 |
| Subject: | RE: [PHP-DB] possible Error in Querydefiniton | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-22252@lists.php.net to get a copy of this message | ||
Use mysql_error() in your die() message to find out what the problem
was...
---John Holmes...
> -----Original Message-----
> From: root@linux [mailto:root@linux] On Behalf Of Ruprecht Helms
> Sent: Monday, October 07, 2002 4:17 AM
> To: John W. Holmes
> Cc: php-db@lists.php.net
> Subject: RE: [PHP-DB] possible Error in Querydefiniton
>
>
> Hi John W. Holmes,
>
> > You can find out why with mysql_error(), but it's probably because
you
> > haven't selected a database with mysql_select_db().
>
> now I have this code, but with the same result
>
> <?
> mysql_connect("localhost","root");
> mysql_select_db("finance");
> mysql_db_query("finace","INSERT INTO buchung (Bezeichnung) VALUES
> ('b')")or
> die("Queryfehler");
> ?>
>
> I always become the die-message. I'm using PHP Version 4.0.6
>
> Regards,
> Ruprecht
>
>
> ------------------------------------------------------------
> Ruprecht Helms IT-Service und Softwareentwicklung
>
> Tel/Fax: +49[0]7621 16 99 16
> email: info@rheyn.de
> Homepage: http://www.rheyn.de
>
>
> -------------------------------------------------------------
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php