I am trying to execute a query with a WHERE clause but it looks like the id I retrieve needs to be perhaps converted from an array into something else. I am new to PHP so I am struggling a little:
...some previous query here
$sharepoint_id = $data[0];
//returns Array([ID] => a5f415a7-3d4f-11e5-b52f-b82a72d52c35)   
qry = mysql_query("SELECT HostName FROM MSSWireList WHERE id=".$sharepoint_id);     
    $data = array();
    while($rows = mysql_fetch_array($qry))
    {
        $data[] = array(
                    "ID"          => $rows['ID'],
                    "Record"      => $rows['Record'],                                
                    "HostName"    => $rows['HostName']
                    );
    }
    return json_encode($data);  
also tried $sharepoint_id = $data[0]->ID; Thank you
 
     
     
    