FPiette 382 Posted July 11 At runtime, I need to discover the structure of a MySQL table (Field names, types, sizes and more]. FireDAC TFDMetaInfoQuery component is supposed to do that but it doesn't work as expected. I got this error message: [FireDAC][Phys][MySQL]-339. A meta data argument [table type name] value must be specified. Don't tell me to use the auto-created fields. Share this post Link to post
Dmitry Arefiev 101 Posted July 11 Please, show your code to query meta-data Share this post Link to post
FPiette 382 Posted July 11 (edited) 56 minutes ago, Dmitry Arefiev said: show your code to query meta-data Just a single line: FDMetaInfoQuery1.Open; TFDMetaInfoQuery is connected at design time to a TFDConnection. The same connection is used for several TFDQuery and every request works file. Extract from the DFM: object FDMetaInfoQuery1: TFDMetaInfoQuery Connection = FDConnection1 MataInfoKind = mkTableTypeFields TableKinds = [tkTable] SchemaName = 'MySchema' Left = 328 Top = 64 end Edited July 11 by FPiette Share this post Link to post
Lajos Juhász 293 Posted July 11 In your example you are missing the ObjectName property it must contain the name of the table that you are querying the fields information. Share this post Link to post
FPiette 382 Posted July 11 58 minutes ago, Lajos Juhász said: ObjectName property it must contain the name of the table that you are querying the fields information That was it. Thanks. Share this post Link to post