Page 1 of 1

Bug (or limitation) in MyDac ?

Posted: Tue 05 Aug 2008 16:31
by kaffeburk
The following properties are not set correct when a tMyQuery is opend:

FieldDefs[].DataType;
FieldDefs[].Precision;
FieldDefList[].DataType;
FieldDefList[].Precision;
-----
GetDataType
GetFieldPrecision

Posted: Wed 06 Aug 2008 12:05
by Dimon
Please describe the problem in more details.

Posted: Wed 06 Aug 2008 12:25
by kaffeburk
Dimon wrote:Please describe the problem in more details.
When the property's are accessed, the values are wrong. Only the name property works correct. For example:

s:= myQuery.FieldDefList[0].Precision;

will always return 0 if Field[0] is a varchar. I guess MyDac don't need this information internally and therefore never sets the properys when a query is opened. The fieldnames it does need, and therefore sets them correct. Im not 100% sure the datatype sets correct or not - but the precision definetly does not.

Just try to get the precision out of a field in a query and you will see it dosent work.

Posted: Fri 08 Aug 2008 06:20
by Dimon
The TFieldDef.DataType property is always set correctly. About the Precision property we have answered you in another thread.