Question with SELECT on Timestamp field in NET-Mode
Posted: Fri 06 Jan 2006 13:25
When I build a SELECT statement with a WHERE clause on a timestamp field, I have a different behaviour of TOraQUERY in normal and net mode.
In normal (= not net) mode I have to define date and time in country dependent format (germany: 'dd.tt.yyyy hh:mm:ss') for WHERE clause and altering value via FieldByName().AsString.
In net mode I have to define date and time in the format 'dd-mmm-yyyy hh:mm:ss' (e.g. 01-Dec-2005 17:00:00) for WHERE clause and country dependent format for altering value via FieldByName().AsString.
Any setting of TOraSession.Options.DateLanguage has no effect.
Is this a well known and also "wanted" behaviour?
Is there perhaps a "workaround" or can I set a value to have a similar
reaction in both modes?
My problem is that I can't use the same code for both modes now.
best regards (and a nice weekend)
Gunter
In normal (= not net) mode I have to define date and time in country dependent format (germany: 'dd.tt.yyyy hh:mm:ss') for WHERE clause and altering value via FieldByName().AsString.
In net mode I have to define date and time in the format 'dd-mmm-yyyy hh:mm:ss' (e.g. 01-Dec-2005 17:00:00) for WHERE clause and country dependent format for altering value via FieldByName().AsString.
Any setting of TOraSession.Options.DateLanguage has no effect.
Is this a well known and also "wanted" behaviour?
Is there perhaps a "workaround" or can I set a value to have a similar
reaction in both modes?
My problem is that I can't use the same code for both modes now.
best regards (and a nice weekend)
Gunter