Re: DB connection problem?

From: Date: Mon, 16 Apr 2001 13:10:23 +0000
Subject: Re: DB connection problem?
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-8598@lists.php.net to get a copy of this message
Hi, is the query-line your line 35 or not? for further debugging put a if (! $result){ echo mysql_error(); } into the script to see what errormsg you get. Johannes ""Andrew Durk"" <adurk@aics.net> schrieb im Newsbeitrag news:9b9nad$9oi$1@toye.p.sourceforge.net... > I can get connected to my host's MySQL database w/o error, but I cannot seem > to do anything after that. > > I do: > $db = mysql_connect("localhost", "username"); > mysql_select_db("subsurface_net",$db); > > No problem, but if I do this: > $result = mysql_query("SELECT * FROM customer_genre",$db); > > I eventually get: > Warning: 0 is not a MySQL result index in /test.phtml on line 35 > > And customer_genre _is_ a table in my database... > > Help, anyone!? > -- > Andrew Durk > adurk@aics.net > > > > > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net > For additional commands, e-mail: php-db-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.db (#8598) next »