level 1
长虹64
楼主
首先请理解一个新手没有老师的情况下会提一些很白的问题。
procedure TForm1.Button3Click(Sender: TObject);
begin
//edit1.text:=*ok*;
//edit1.text:=inttostr(select max(*题号*) from table1);
edit1.text:=select max(*题号*) FROM table;
end;
报错三项
[错误] Unit1.pas(84): Undeclared identifier: *select*
[错误] Unit1.pas(84): Missing operator or semicolon
[致命错误] Project1.dpr(5): Could not compile used unit *Unit1.pas*
表是用Database Desktop建的,题号 数据类型是 I (长整型)
我想的是将表中加入一道题时,主键‘题号’自动加一。
我的思路是:先找到表中题号的最大值再加一放入edit1中再写入表里。
2014年08月15日 13点08分
1
procedure TForm1.Button3Click(Sender: TObject);
begin
//edit1.text:=*ok*;
//edit1.text:=inttostr(select max(*题号*) from table1);
edit1.text:=select max(*题号*) FROM table;
end;
报错三项
[错误] Unit1.pas(84): Undeclared identifier: *select*
[错误] Unit1.pas(84): Missing operator or semicolon
[致命错误] Project1.dpr(5): Could not compile used unit *Unit1.pas*
表是用Database Desktop建的,题号 数据类型是 I (长整型)
我想的是将表中加入一道题时,主键‘题号’自动加一。
我的思路是:先找到表中题号的最大值再加一放入edit1中再写入表里。
