For Programmers: Free Programming Magazines  


Home > Archive > PHP Language > February 2005 > Re: MySql / php newbie question: retrieving results that are not









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: MySql / php newbie question: retrieving results that are not
Sebestyén Dénes

2005-02-26, 3:56 pm

Yevgen Varavva írta:
> "Martien van Wanrooij" <info@martienvanwanrooij.nl> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ ×
> ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ: news:KH%Td.3387$Mw3.1702@amstwist00...
>
>
> Try putting
> ====================
> echo mysql_error();
> ====================
> after your mysql_query() line.
>
>


I solved this problem usually this way:

$res = mysql_query("some query string...") or die(mysql_error());

or an advanced version if you use variables in the query too:

$res = mysql_query($qry="some query string...") or
die("$qry<br>".mysql_error());
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com