Home > SQL and SQL Server Tutorial and Reference Guide
Learning Guide:
EMAIL THIS

SQL and SQL Server Tutorial and Reference Guide

31 Jul 2008 | SearchSQLServer.com

Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   

SQL (Structured Query Language) is the language of databases. This "Back to Basics" SQL tutorial provides a great starting point and foundation for learning SQL or brushing up your skills.

This SQL Server tutorial will continue to be updated with content from SQL Server guru Denny Cherry, so please bookmark this page and return for regular updates.

SQL Tutorial and Reference
To start learning SQL Server basics, simply click a link below to jump to a section.

  → The four basic SQL statements
  → SQL and SQL Server tutorials
  → Visit the SQL Server with Mr. Denny blog

   What is IT Knowledge Exchange?
IT Knowledge Exchange (ITKE) is a community of IT pros that share and pool their knowledge. You can ask your own IT question or share your expertise by answering a question. Do you have an IT problem that's driving you crazy? Come ask your peers and colleagues on IT Knowledge Exchange. You can even start your own blog and earn some cash for posting regularly.

  → Visit the ITKE Community Blog to learn how to get IT answers

  ↓ The Four Basic SQL Statements Table of Contents   

The SELECT statement
There are four basic commands in databases; SELECT, INSERT, UPDATE and DELETE. The most important of these is probably the SELECT statement, which is used to retrieve and display the data from the database.

The INSERT statement
While the SELECT statement is arguably the most important command, the INSERT comes in a close second. The INSERT statement is used to do exactly what it sounds like, this command inserts data into a database table.

The UPDATE statement
After data has been inserted into a table, you will at some point wish to update that data.This is done by using the UPDATE statement. The UPDATE statement can update a record or a set of records in a database table.

The DELETE statement
The DELETE statement is used when you wish to remove data from a table. Using the DELETE statement without a WHERE clause will remove all the data from your table. The WHERE clause works the same way as the WHERE clause for SELECT and UPDATE statements.

  ↓ SQL and SQL Server Tutorials Table of Contents   

SQL Server Tables
Tables are the core of any database platform. Without SQL Server tables, there would be no way to store the data that we process. On the surface, tables may look similar to the rows and columns of a spreadsheet but they are very different.

CTE (Common Table Expressions)
One of the new features introduced in SQL Server 2005 was CTE (Common Table Expressions). In their simplest, most common form, you can think of them as a temporary, single use view.

SQL Server Views
Views are strange objects. They look like tables, can be queried like tables, but SQL Server Views don't store any actual data. Think of them as a virtual table which points to the source tables. Views can combine data from one or more tables via JOIN, just like a SELECT statement.

SQL Filters: JOIN vs. EXISTS vs. IN
Not all filters are the same. You can learn about filters in this comparison of JOIN vs. EXISTS vs. IN. Different filtering operations are used at different times to get the best performance out of your SQL Server.

SQL Server Endpoints
People, and applications, connect to SQL Server by way of endpoints. There are four different types of SQL Server endpoints; SERVICE_BROKER, DATABASE_MIRRORING, SOAP and TSQL.

Logins and Users
You'll sometimes see the terms Logins and Users used interchangeably. However, in Microsoft SQL Server, they are two very different things. Because everyone assumes that they are the same thing, it can get a little confusing.

The sp_change_users_login procedure
The specific purpose of the sp_change_users_login procedure is to identify and correct the users within a database that do not have corresponding logins.

SQL Functions
SQL functions create little blocks of code. Functions are fantastic for converting data from one format to another or for looking up other values based on a lookup. However, this comes at a price. That price is CPU power.

SQL Stored Procedures
Stored procedures are extremely useful objects. Not only do they store T/SQL scripts for later execution, but stored procedures also provide an extremely important security barrier between the user interface and the database.

SQL Server Memory Settings
Tweaking the memory settings just right in 32-bit versions of SQL Server can be tricky. Here's how to configure the memory setting in SQL Server.

The BACKUP DATABASE command
The BACKUP DATABASE command takes backups of the database, along with all tables, views, procedures and functions. This secures your information in case of a server failure or accidental data deletion.

The RESTORE DATABASE command
The RESTORE DATABASE command is what is used to recover a database which has been backed up using the BACKUP DATABASE command. The syntax of this command is very similar to the BACKUP DATABASE command in many respects..

   GOT IT QUESTIONS? YOUR PEERS HAVE ANSWERS
Your peers and colleagues have faced the same or similar problems.
So ask your own question on the IT Knowledge Exchange community.


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


RELATED CONTENT
SQL/Transact SQL (T-SQL)
Avoid cursors in SQL Server with these methods to loop over records
Implementing security audit in SQL Server 2008
New datetime data types in SQL Server 2008 offer flexibility
Basic objects of T-SQL in SQL Server 2008
Using T-SQL data types in SQL Server 2008
SQL Server 2008 function types in T-SQL
Additional T-SQL operations in SQL Server 2008
Using DATEADD and DATEDIFF to calculate SQL Server datetime values
Manipulate column names in a SQL Server table
SQL Server trigger vs. stored procedure to receive data notification
SQL/Transact SQL (T-SQL) Research

SQL Server stored procedures
SQL Server trigger vs. stored procedure to receive data notification
How to use SQL Server 2008 hierarchyid data type
SQL Server stored procedures tutorial: Write, tune and get examples
Check SQL Server database and log file size with this stored procedure
SQL Server source code analysis and management adds database security
Configure SQL Server Service Broker for sending stored procedure data
Find size of SQL Server tables and other objects with stored procedure
Track changes to SQL Server 2000 and 2005 with one simple utility
Troubleshoot SQL Server 2005 temporary table performance problems
Use SQL Profiler to find long running stored procedures and commands

SQL Server overview
How to configure storage in SQL Server DB with more writes than reads
Avoid cursors in SQL Server with these methods to loop over records
Solve SQL Server errors and more from the DBA trenches -- part 2
Tutorial: Learn SQL Server basics from A-Z
FAQ: Troubleshooting SQL Server Reporting Services
SQL Server replication methods: Snapshot, merge or transactional
New security features in SQL Server 2008 leave some work for you
How to disable the shrink database task in SQL Server 2000 and 2005
New datetime data types in SQL Server 2008 offer flexibility
SQL Server out of memory: Troubleshoot and avoid SQL memory problems
SQL Server overview Research

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
ACID  (SearchSQLServer.com)
commit  (SearchSQLServer.com)
DAO  (SearchSQLServer.com)
fetch  (SearchSQLServer.com)
OLE DB  (SearchSQLServer.com)
query  (SearchSQLServer.com)
SQL  (SearchSQLServer.com)
T-SQL  (SearchSQLServer.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary




Secure SQL - Data Security for Your Database
HomeNewsTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersIT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




All Rights Reserved, Copyright 2005 - 2008, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts