Sql tutorial-for-beginners-with-examples-and-sql-tutorial-pdf


Published on


Published in: Education
1 Comment
  • Search more than 5000 IT certified Trainers at http://www.todaycourses.com
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Sql tutorial-for-beginners-with-examples-and-sql-tutorial-pdf

  1. 1. Katie & Emil >BI Tutorials >SQL > sql tutorial for beginnerssql tutorial for beginners Below you can find our SQL tutorial that is mostly suitable for beginnersand those who want to learn something new. It covers SQL language only that usually can be applied to any software. We will use SQL Server 2008 R2 for our examples but most examples should work in different versions. Enjoy our SQL Server Tutorial Each tutorial will have plenty of examples andscreenshots that hopefully will help those who are new to SQL digest everything muchquicker and gain understanding of the language in much shorter period of time. What wedon’t necessarily show is proper and full syntax which we believe is usually too much forsomeone who just wants to learn something useful and use it in practise therefore we decidedto provide always a few real life example in each tutorial page.SQL Tutorial What is a database? - Learn the basics of database concepts. I strongly recommend this tutorial page. o Normalization Process - to be created o Reasons for normalization - We describe three main reasons for normalization in a database. What is SQL? - Find out what is SQL and what it is used for. SQL Clauses list - Find out what is the correct order of SQL Clauses SQL SELECT - Learn how to retrieve data from table(s) using SQL Select Statement. SQL WHERE -Learn how to filter results/records with SQL WHERE Clause. SQL GROUP BY -Learn how to Group By records with SQL GROUP By Clause. o SQL GROUP BY with Count o SQL Group by Year from Date field SQL Union - Learn how to combine two or more queries using UNION operator SQL Except - Learn how to show unique results of first query excepts results of second queryData Manipulation Language tutorial (DML):Data Manipulation Language (DML) - Find out more about DML
  2. 2.  SQL UPDATE -In this tutorial you will learn how to update records with where and joins using SQL Update SQL INSERT multiple rows -In this tutorial you will learn how you can using SQL insert multiple rows at once. SQL INSERT DATE - In this tutorial you will learn how to insert date into a field using SQL INSERT SQL INSERT if not exists - In this tutorial you will learn how to insert row if it does not already exist. SQL Joins Examples - shows to simple examples of inner and left outer joins.Data Definition Language tutorial (DDL): Data Definition language (DDL) - Find out more about DDL SQL CREATE TABLE SQL ALTER TABLE o Constraints o SQL Primary Key Constraint o SQL Check Constraint o SQL DEFAULT CONSTRAINT o SQL UNIQUE Constraint SQL DROP Statements o SQL DROP TABLE o SQL DROP VIEW o SQL DROP PROCEDURE o SQL DROP FUNCTION SQL CREATE VIEWSQL Server TutorialBelow are articles that are more specifc to SQL Server.SQL Server Performance tuning overviewSQL Check if column existsSQL Check if table existsSQL Check if record existsSQL Check if record exists before insertSQL Check if record exists before updateSQL Convert date and time int into datetimeSQL Check if schema existsSQL age bands
  3. 3. SQL Find table sizeSQL add primary key to table with existing primary keySQL Substring functionSQL Update progress statusSQL Server SoundexSQL Server move database to a different driveSQL Server Shrink log fileT-SQL Current Date Using current date is one of the most common element when writing t-sql queriesT-SQL Current Time Getting current time from a field is common requirement although notso obvious in T-SQLT-SQL YYYYMMDD This is one of them most common function used in data warehousesT-SQL Month Name This is easily achieved using T-SQL functionT-SQL Last Month This is probably most often used by finance related reportsT-SQL Day Of Week Getting day of week is simple although users can complicate it. Sunday= 1 or Monday = 1T-SQL Find column name in database in any tableSQL Show running queriesT-SQL Check if database object existsSQL Add Columnsql case sensitive string comparisonSQL Server orphaned usersSQL check if temp table existsSQL Server wait for delaySQL Update progress statusSQL Server restore databaseSQL Server 2012 Add user login with sql server authanticationSQL Server 2012 AdventureWorks DW download and installOther:SQL Server Compressed backup without enterprise editionSQL Server add Linked ServerThe following link shows SQL Queries Examples from beginner to advanced