You are not logged in.
Pages: 1
when i use DateToIso8601 in a Query, i alway's got a result
from commit 1536 I get no result any more
when I change DateToIso8601 to DateToIso8601Text and put it between "" then i get my result again.
does this mean that i had to change al my DateToIso8601 (to DateToIso8601Text and between "") or is there an issue with DateToIso8601 ?
Offline
var
S: RawUTF8;
D: TDateTime;
Info: TSQLTableJSON;
before this was OK
S := ('Datum >= ' + DateToIso8601(D, False) + ' and ' +
'Datum <= ' + DateToIso8601((D + 6), False));
Info := Server.ExecuteList([TSQLInfoTable],
S2U('SELECT * FROM InfoTable WHERE ') + S);
Now need to use DateToIso8601Text within ""
S := ('Datum >= "' + DateToIso8601Text(D) + '" and ' +
'Datum <= "' + DateToIso8601Text(D + 6) + '"');
Info := Server.ExecuteList([TSQLInfoTable],
S2U('SELECT * FROM InfoTable WHERE ') + S);
Offline
Use ? parameters
also with ? parameters i only get a result with DateToIso8601Text
DateToIso8601 gives no result any more
Offline
Info := Server.ExecuteFmt([TSQLInfoTable], 'SELECT * FROM InfoTable WHERE Datum >= ? and Datum <= ?',[],[DateToSQL(D),DateToSQL(D+6)]);
ehh, i cannot use ExecuteFmt like this?
the result of ExecuteFmt is Boolean, I need TSQLTableJSON
Last edited by Bojop (2015-07-08 11:44:12)
Offline
Pages: 1