if (FDQuery.FieldDefList.FieldDefs[i].Name <> 'TKey') and (FDQuery.FieldByName(FDQuery.FieldDefList.FieldDefs[i].Name).AsString <> '') then
begin
.......
end
I are migrating code from NexusDB to using MySql.
The table in question has data in it as this line works
a := FDQuery.FieldByName('Employee').AsString;
The if statement above worked fine using TnxTable.
This portion of the statement works "FDQuery.FieldDefList.FieldDefs[i].Name" as the field names tick over in the loop. however the data in the field does not get read.
What am I doing wrong or how do I do the same thing different.
Thanks
Daniel