SQL Basics SQL 基础
When you interact with a data source through ADO.NET, you use SQL to retrieve, modify, and update information. In some cases, ADO.NET will hide some of the details for you or even generate required SQL statements automatically. However, to design an efficient database application with a minimal amount of frustration, you need to understand the basic concepts of SQL.
当你通过ADO.NET与一个数据源交互,您使用SQL来检索,修改和更新信息。在某些情况下, ADO.NET将隐藏的一些细节,甚至自动生成所需的SQL语句。然而,用最少的挫折设计一个有效的数据库,你需要了解SQL的基本概念。
SQL (Structured Query Language) is a standard data access language used to interact with relational databases. Different databases differ in their support of SQL or add other features, but the core commands used to select, add, and modify data are common. In a database product such as SQL Server, it’s possible to use SQL to create fairly sophisticated SQL scripts for stored procedures and triggers (although they have little of the power of a full object-oriented programming language). When working with ADO.NET, however, you’ll probably use only the following standard types of SQL statements:
SQL(结构化查询语言)是一种标准的数据存取语言,用来与关系型数据库互动。不同的数据库支持不同的SQL语句或添加其他功能,但用于选择、添加和修改数据的核心命令是共同的。在数据库产品如SQL Server ,很可能使用SQL创建相当复杂的SQL脚本,如存储过程和触发器(尽管他们在面向对象的编程语言中有很少充分的作用)。然而当使用ADO.NET时,你可能只使用下列标准类型的SQL语句:
• A Select statement retrieves records.
• An Update statement modifies existing records.
• An Insert statement adds a new record.
• A Delete statement deletes existing records.
• SELECT语句检索记录。
•Update语句修改现有记录。
•INSERT语句增加一个新的纪录。
•Delete语句删除现有记录。
If you already have a good understanding of SQL, you can skip the next few sections. Otherwise, read on for a quick tour of SQL fundamentals.
如果您已经对SQL有一个很好的了解,你可以跳过下几节。 否则,快速浏览SQL的基础。
Tip To learn more about SQL, use one of the SQL tutorials available on the Internet, such as the one at http://www.w3schools.com/sql. If you’re working with SQL Server, you can use its thorough Books Online help to become a database guru.
提示:若要了解更多有关SQL ,使用在互联网上提供的SQL教程,如在 http://www.w3schools.com/sql 。如果使用SQL Server ,您可以使用它的在线帮助,将使您成为一个数据库大师。