I was reading a previous post about connecting to an Index Server from another computer. However, I'm having a problem connecting to my remote server due to it's name. It is called h01ny-nt2 and the problem is caused by the "-" symbol. It causes a syntax error and expected end-of-file. I can't use the IP address either because the dots in it conflict with the rest of the statement. Here is my code:
$link = oledb_open("Provider=MSIDXS; Data Source=OfficeProcedures");
$server = 'h01ny-nt2';
$keyword = 'FORMSOF (INFLECTIONAL, '.$_REQUEST['Title'].')';
$sql = "SELECT filename, size, path
FROM $server.OfficeProcedures..SCOPE()
WHERE CONTAINS(Contents, '$keyword')";$res = oledb_query($sql, $link);
while($row = oledb_fetch_assoc($res))
{
var_dump($row);}
Any help would be greatly appreciated. Thank you for your time and attention.