Page 1 of 1

empty result

Posted: Tue Feb 10, 2009 9:26 am
by pppswing
Hello,

I have a query

$query= "SELECT DATE_ADD('".$mydate."', INTERVAL 1 HOUR)";

that gives a good result on phpMyAdmin.

But when I do in php

$result = mysql_query($query);

$result is empty, I can't undersdand why
I've done a mysql_error() but there is no error and the database link is OK,

I can do other queries previously but when I'm trying to get the date it doesn't work.

Thanks,
:)

Re: empty result

Posted: Tue Feb 10, 2009 9:35 am
by papa

Re: empty result

Posted: Tue Feb 10, 2009 9:49 am
by pppswing
No, the problem is that $result is empty

I know how to retrieve the data with mysql_result($result,0,0); this part is OK but I can't get any result and any error !