Question

I'm trying to fetch data from my DB.
It works great when there are no hebrew chars involved, but it doesn't work with hebrew chars.
Here's a query for example:

while (list($ddd, $ccc) = each($dbb)){
$dsn = "DRIVER={SQL Server}; SERVER={$ccc};UID={$usr};PWD={$pwd}; DATABASE={$ddd}";
$db->Open($dsn);
$SQL = "SELECT TOP 10 CardCode FROM dbo.OPDN WHERE Cast(CardCode AS Nvarchar(max)) = N'רונלייט'";
$rs = $db->Execute($SQL);
$qqqw='';
while(!$rs->EOF){
    echo ($rs->Fields['CardCode']);
    echo "<br />";
   $rs->MoveNext();
}
$rs->Close();
$db->Close();
}

Help would be highly appreciated.

Was it helpful?

Solution

Got it!
Problem was with the file encoding.
It should have been in "ASCI".

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top