Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Read a Record with TQuery and SQL 1

Status
Not open for further replies.

luistsousa

Technical User
May 12, 2003
66
PT
Hi

How can I read a record in a mysql table using a Query1.SQL state?

Regards
 
example:

query1.SQL.Clear;
query1.SQL.Add('Select employee_code from employee_table');
query1.SQL.open;

while not(query1.eof) do
begin
{this is data which you read from the table}
--> query1.fieldbyname('employee_code').asstring;
end;

Hopefully my example can help you
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top