What Are the Differences Between T-Sql, SQL Server and SQL

What are the differences between T-SQL, SQL Server and SQL

SQL is the basic ANSI standard for accessing data in a relational database. When you see "MSSQL" it is referring to Microsoft SQL Server, which is the entire database architecture and not a language. T-SQL is the proprietary form of SQL used by Microsoft SQL Server. It includes special functions like cast, convert, date(), etc. that are not part of the ANSI standard.

You will also see things like plSQL, which is Oracle's version of SQL, and there are others as well (mySQL has its own version, for example, and Microsoft Access uses Jet SQL.)

It is important to note the the ANSI standard for SQL has different releases (for example, 92 or 99, representing the year it was released.). Different database engines will advertise themselves as "mostly ANSI-92" compliant or "fully ANSI-99" compliant, etc, and any exceptions will usually be documented.

So although "SQL is SQL", every engine uses its own "flavor" of it, and you do have to do a little reading on the particular platform before you just dive in.

A further note - the SQL extensions, like T-SQL, are generally considered full-fledged programming languages, complete with looping, if/then, case statements, etc. SQL itself is limited to simply querying and updating data and is not considered a true programming language.

Wikipedia has a decent article for an overview here:
http://en.wikipedia.org/wiki/SQL

What is the difference between MSSQL and TSQL?

MS SQL is simply a short version of the (complete) product name Microsoft SQL Server. (Similar to "MS Office", "MS Windows" or "MS Access").

T-SQL is the SQL dialect that the product Microsoft SQL Server is using - and is short for "Transact-SQL" (thanks Aaron for reminding me!)

I wouldn't call the dialect that Microsoft Access is using SQL. It's a query language that somehow resembles SQL

What is the difference between SQL, PL-SQL and T-SQL?

  • SQL is a query language to operate on sets.

    It is more or less standardized, and used by almost all relational database management systems: SQL Server, Oracle, MySQL, PostgreSQL, DB2, Informix, etc.

  • PL/SQL is a proprietary procedural language used by Oracle

  • PL/pgSQL is a procedural language used by PostgreSQL

  • TSQL is a proprietary procedural language used by Microsoft in SQL Server.

Procedural languages are designed to extend SQL's abilities while being able to integrate well with SQL. Several features such as local variables and string/data processing are added. These features make the language Turing-complete.

They are also used to write stored procedures: pieces of code residing on the server to manage complex business rules that are hard or impossible to manage with pure set-based operations.

What is the difference between PL/SQL and T-SQL?

T-SQL and PL/SQL are two completely different programming languages with different syntax, type system, variable declarations, built-in functions and procedures, and programming capabilities.

The only thing they have in common is direct embedding of SQL statements, and storage and execution inside a database.

(In Oracle Forms, PL/SQL is even used for client-side code, though integration with database-stored PL/SQL is (almost) seemless)

Difference between T-SQL and MySQL's SELECT syntax

Node.js does support SQL Server e.g. mssql package.

Both DBMS products support a common subset of ANSI/ISO standard SQL and have proprietary extensions as well. The effort to convert the app to MySQL will depend on what proprietary features are used as well as ANSI SQL constructs used that not yet implemented in MySQL.

What is difference between != and in sql server

There is no difference. You can use both in MSSQL.

The MSSQL doc says:

!= functions the same as the <> (Not Equal To) comparison operator.

But <> is defined in the ANSI 99 SQL standard and != is not. So not all DB engines may support it and if you want to generate portable code I recommend using <>.

T-SQL differences between SQL Server Compact Edition and real SQL Server?

  • SQL Reference (SQL Server Compact 4.0)

SQL Server Compact supports only the Transact-SQL grammar documented in this section. SQL Reference for SQL Server Compact is a subset of
Transact-SQL for SQL Server.

  • Syntax conventions and query elements

Syntax Conventions

  • Data Types

SQL Server Compact 4.0 supports the following data types.

  • Functions

SQL Server Compact supports the following functions.

  • Information Schema

The following table lists Information Schema views that are supported by SQL Server Compact.

  • Operators

SQL Server Compact supports the following operators.

  • Reserved Words

A reserved word in SQL Server Compact does not necessarily function the same way as the corresponding word in SQL Server. The following table lists the reserved words in SQL Server Compact.

  • Features not supported in SQL Server Compact 4.0

Starting with SQL Server Compact 4.0, there are few scenarios and features that are not supported by SQL Server Compact. This topic gives a brief account of features that were supported by the preceding versions of SQL Server Compact, including SQL Server Compact 3.5 SP2.

  • Differences Between SQL Server Compact and SQL Server

Use the following table to determine which Transact-SQL commands, features, and data types are supported by SQL Server Compact, compared with SQL Server.

previous version:

  • SQL Server Compact 3.5 SP2 - SQL Reference

  • SQL Server Compact 3.0 - SQL Reference

Difference between and != in SQL

None whatsoever, syntactically.

Both are inequality operators, <> is the SQL-92 standard, however its interchangable on some platforms with != (E.g. SQL Server)



Related Topics



Leave a reply



Submit