On 04.10.2012 13:13, H M wrote: > The problem is that DISQLiteUNIDirQuery does not seem consistant in the > data types its returns for similar SQL, so sometimes the money amount > comes back as a TDSQLite3WideStringField type and so there is no > DisplayFormat property available in the ClientDataSet and the amount > displays incorrectly. > > I've tried using OnInitFieldDef to force the datatype to be TFloatField > but then get errors along the lines of 'expecting TFloatField but > received TDSQLite3widestringField '. > I've tried playing with query field editor and even tried altering the > type in the source code of the datamodule class, all to no avail. > > Is there a 'proper' way to make sure that SQL calculations resulting in > floats get returned by DISQLiteUNIDirQuery as floats ? I'd need to see your database and a small sample application (source code only) to tell exactly what's going on. Could you please send them to <delphi@xxxxxxxx> or upload it to a server and post the link here? Ralf _______________________________________________ Delphi Inspiration mailing list yunqa@xxxxxxxxxxxxx //www.freelists.org/list/yunqa