D E L P H I 's Search Engine : FunnyLogo.info : Personal Search Engine Maker of Style Yahoo

 

Web ImagesVideoNewsMapsBooks More»
 
 Advanced Search
 Preferences
 Language Tools


BookMark     Create your own Search Engine Now


FunnyLogo is not affiliated with Google Inc.
Trademarks remain trademarks of their respective companies.
© 2007 FunnyLogo

Sedo - Buy and Sell Domain Names and Websites project info: funnylogo.info Statistics for project funnylogo.info etracker® web controlling instead of log file analysis

Rabu, 07 November 2007

Insert, Update, Delete dg SQL

// Insert record
procedure TForm1.Button1Click(Sender: TObject);
begin
with Query1 do
begin
Active:=False;
SQL.Clear;
SQL.Add('Insert into country(NAME,CAPITAL,CONTINENT,AREA,POPULATION)
values(
''A_My_Country'',
''A_My_Capital'',
''A_My_Continent'',
1,
1)');
ExecSQL;
end;
Table1.Refresh;
end;


// Delete record
procedure TForm1.Button2Click(Sender: TObject);
begin
with Query1 do
begin
Active:=False;
SQL.Clear;
SQL.Add('Delete from country where name=''A_My_Country''');
ExecSQL;
end;
Table1.Refresh;
end;

//Update record
procedure TForm1.Button3Click(Sender: TObject);
begin
with Query1 do
begin
Active:=False;
SQL.Clear;
SQL.Add('Update country set name=''A_Your_Country''
where name=''A_My_Country''');
ExecSQL;
end;
Table1.Refresh;
end;