I have a strange problem and can't find a reason for it.
I have a UniConnection and an UniQuery.
The statement of the UniQuery is something like that:
Code: Select all
SELECT IC_Nachrichten.id, IC_Prioritaeten.Bezeichnung AS Prioritaet
FROM IC_Nachrichten
LEFT JOIN IC_Prioritaeten ON IC_Prioritaeten.ID = IC_Nachrichten.ID_IC_Prioritaeten
WHERE ID_Personal_von = 2
The strange problem:
When I output the value of the field "Bezeichnung" it gives me some strange character instead of an empty string.
procedure TForm1.Button1Click(Sender: TObject);
begin
UniQuery1.Open;
showmessage(UniQuery1Prioritaet.AsString); // outputs somethins like "Ұ", but the value is definetly "null"
UniQuery1.Close;
end;
The UniConnection is set to unicode, and the fields of the database tables are defined as nVarChar fields.
I could provide you a sample application + sample database to reproduce this problem.
Thank you very much for you help!
System information:
Delphi 2009
UniDac version 3.50.0.13
Sybase Advantage Database Server 10.10