SQL and PHP
Posted: Wed Sep 11, 2002 9:08 am
<?
results in:
=count
=max
How do I refer to count(name) and max(name) in php after the querry?
I have echo'd out the querry and inserted it nativly into the database and gotten the results I expected so values for each are being returned. Any ideas?
Direwolf
Code: Select all
$sql="select count(name),max(name) from regen_vals
where job='".$session_infoї'order']."'
and loc_code='".$session_infoї'loc_code']."'
and name like 'UNIT%_LENGTH'";
$qry=ifx_query($sql,$dbid);
$row=ifx_fetch_row($qry,"next");
echo $rowї'count']."=count\n";
echo $rowї'max']."=max\n";
ifx_free_result($qry);
?>=count
=max
How do I refer to count(name) and max(name) in php after the querry?
I have echo'd out the querry and inserted it nativly into the database and gotten the results I expected so values for each are being returned. Any ideas?
Direwolf