我使用DELPHI7.0+dbExpress+IB7.0。
程序中如何判断用户所想要创建的数据库表是否已经存在。
程序中如何判断用户所想要创建的数据库表是否已经存在。
解决方案 »
- 请教fastReport打印主从报表
- delphi7中有两个DateTime变量相加的方法吗?
- 超级郁闷,装了IE7.0,无法上传文件了,,,,
- 请问大家:TCompressStream()的压缩比有多少?
- 动态添加的字段能否在第一个???
- 请教下数学函数问题我老是试不对
- 请问,在查询摸块上填入查询条件在edit控件里面,按回车怎样激活旁边的查询按钮
- 怎样在StringGrid中加入其他控件
- 请问Class TIELabel 的作用?怎样在面板上添加该类组件?谢谢!
- 像那种按钮旁边有一个向下的箭头,单击可以弹出一个下拉菜单的组合按钮是怎么做的?
- 兼职,谁做?
- 一个比较简单的问题!是关于ADOQuery的!
Active := False;
DatabaseName := 'DBDEMOS';
TableType := ttParadox;
TableName := 'CustInfo'; { Don't overwrite an existing table } if not Table1.Exists then begin
{ The Table component must not be active }
{ First, describe the type of table and give }
{ it a name }
{ Next, describe the fields in the table }
with FieldDefs do begin
Clear;
with AddFieldDef do begin
Name := 'Field1';
DataType := ftInteger;
Required := True;
end;
with AddFieldDef do begin Name := 'Field2';
DataType := ftString;
Size := 30;
end;
end;
{ Next, describe any indexes }
with IndexDefs do begin
Clear;
{ The 1st index has no name because it is
{ a Paradox primary key }
with AddIndexDef do begin
Name := '';
Fields := 'Field1';
Options := [ixPrimary];
end;
with AddIndexDef do begin Name := 'Fld2Indx';
Fields := 'Field2';
Options := [ixCaseInsensitive];
end;
end;
{ Call the CreateTable method to create the table }
CreateTable;
end;
end;
拜托了!!!!!!