What Is a Transact-SQL Statement?
Submitted by: AdministratorA Transact-SQL statement is a basic execution unit of the Transact-SQL language. Here are some examples of Transact-SQL statements:
* "CREATE TABLE ...;" - A data definition language statement that defines a table.
* "INSERT INTO ...;" - A data manipulation language statement that inserts data into a table.
* "SELECT * FROM ...;" - A query statement that returns data from a table.
* "DROP TABLE ...;" - A data definition language statement that deletes a table.
* "DECLARE @name data_type;" - A declaration statement that defines a local variable.
* "SET @name = expression;" - An assignment statement that assigns a value to a local variable.
* "BEGIN TRANSACTION;" - A transaction management statement that marks the beginning of a transaction.
* "ROLLBACK TRANSACTION;" - A transaction management statement that rolls back all changes of a transaction.
Submitted by: Administrator
* "CREATE TABLE ...;" - A data definition language statement that defines a table.
* "INSERT INTO ...;" - A data manipulation language statement that inserts data into a table.
* "SELECT * FROM ...;" - A query statement that returns data from a table.
* "DROP TABLE ...;" - A data definition language statement that deletes a table.
* "DECLARE @name data_type;" - A declaration statement that defines a local variable.
* "SET @name = expression;" - An assignment statement that assigns a value to a local variable.
* "BEGIN TRANSACTION;" - A transaction management statement that marks the beginning of a transaction.
* "ROLLBACK TRANSACTION;" - A transaction management statement that rolls back all changes of a transaction.
Submitted by: Administrator
Read Online MS SQL Server Job Interview Questions And Answers
Top MS SQL Server Questions
☺ | What Is a Transact-SQL Statement Batch in MS SQL Server? |
☺ | How To Execute the Cursor Queries with "OPEN" Statements? |
☺ | What Happens If Strings Are Casted into Wrong Code Pages in MS SQL Server? |
☺ | How To Use Subqueries with the EXISTS Operators in MS SQL Server? |
☺ | What Is a Subquery in a SELECT Query Statement in MS SQL Server? |
Top Databases Programming Categories
☺ | RDBMS Interview Questions. |
☺ | SQL Interview Questions. |
☺ | SSRS Interview Questions. |
☺ | Database Administrator (DBA) Interview Questions. |
☺ | Sybase Interview Questions. |