Re: possible Error in Querydefiniton
| From: | Jason Wong | Date: | Mon, 07 Oct 2002 09:13:15 +0000 |
| Subject: | Re: possible Error in Querydefiniton | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-22251@lists.php.net to get a copy of this message | ||
On Monday 07 October 2002 16:16, Ruprecht Helms wrote:
> 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
Try adding some error checking code. Have a look at the numerous PHP/MySQL
tutorials to find out how it should be done.
--
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
/*
Anarchy may not be a better form of government, but it's better than no
government at all.
*/