I have a program that I want to use a view with. The code I'm using is: $v="select * from peoplecontact".$where." order by ci_city"; The select statement seems to work fine. It returns the correct number of rows. Now, how to I use it (see $entername)?

$v="select * from peoplecontact".$where." order by ci_city";
 $num_rows = mysql_affected_rows();
 $entername=$v['PD_Lname']."  ".$v['PD_Fname'];  //doesn't work

mysql_fetch_array($v) doesn't work either.

Can anyone help with this?
TIA,
Dick Deeds

i dont understand what u are trying to do
if u wanted to use mysql_fetch_array u would need something liek

$result=mysql_query($v); 
while($row=mysql_fetch_array($result)){ // Start looping table row
echo $row[columnname];}
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.