$db select max() from ..
Posted: Tue Feb 03, 2009 4:53 am
Hi;
I am having trouble with the following queries which both return empty results in a UDT, although when I run them in phpmyadmin they work fine !
Any suggestions 
Thanks
P
I am having trouble with the following queries which both return empty results in a UDT, although when I run them in phpmyadmin they work fine !
Code: Select all
$sql = "SELECT max(news_id) as 'next_no' FROM 'cms_module_news'";
$sql = "SELECT max(news_id) FROM 'cms_module_news'";
$db = &$gCms->db;
$dbresult = $db->Execute($sql);
$row = $dbresult->FetchRow();
print_r($row);

Thanks
P