delphi 7 ado_在ADO中使用Delphi查询

delphi 7 ado

The TADOQuery component provides Delphi developers the ability to fetch data from one or multiple tables from an ADO database using SQL.

TADOQuery组件使Delphi开发人员能够使用SQL从ADO数据库的一个或多个表中获取数据。

These SQL statements can either be DDL (Data Definition Language) statements such as CREATE TABLE, ALTER INDEX, and so forth, or they can be DML (Data Manipulation Language) statements, such as SELECT, UPDATE, and DELETE. The most common statement, however, is the SELECT statement, which produces a view similar to that available using a Table component.

这些SQL语句可以是DDL(数据定义语言)语句,例如CREATE TABLE,ALTER INDEX等,也可以是DML(数据操作语言)语句,例如SELECT,UPDATE和DELETE。 但是,最常见的语句是SELECT语句,它产生的视图类似于使用Table组件可获得的视图。

Note: even though executing commands using the ADOQuery component is possible, the ADOCommandcomponent is more appropriate for this purpose. It is most often used to execute DDL commands or to execute a stored procedure (even though you should use theTADOStoredProc for such tasks) that does not return a result set.

注意:尽管可以使用ADOQuery组件执行命令,但ADOCommand组件更适合于此目的。 它最常用于执行DDL命令或执行不返回结果集的存储过程(即使您应将TADOStoredProc用于此类任务)。

The SQL used in a ADOQuery component must be acceptable to the ADO driver in use. In other words you should be familiar with the SQL writing differences between, for example, MS Access and MS SQL.

ADOQuery组件中使用SQL必须对所使用的ADO驱动程序可接受。 换句话说,您应该熟悉MS Access和MS SQL之间SQL编写差异。

As when working with the ADOTable component, the data in a database is accessed using a data store connection established by the ADOQuery component using itsConnectionString property or through a separate ADOConnection component specified in the Connectionproperty.

如同ADOTable组件工作时,在一个数据库中的数据是使用通过使用其ConnectionString属性的ADOQuery组分或通过在连接属性中指定的单独的ADOConnection分量建立的数据存储连接访问。

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值