පාඨමාලා මාතෘකා Microsoft SQL Server Databases සැකසීම

Slides:



Advertisements
Similar presentations
Big Data Working with Terabytes in SQL Server Andrew Novick
Advertisements

Dual Partitioning for improved performance in VLDBs Ashwin Rao Karavadi, Rakesh Parida Microsoft IT.
Company LOGO 1 Database Creation and Maintenance Jorge G. Martinez.
Module 8: Implementing Stored Procedures. Introducing Stored Procedures Creating, Modifying, Dropping, and Executing Stored Procedures Using Parameters.
Module 1: Introduction to Transact-SQL
04 | Grouping and Aggregating Data Brian Alderman | MCT, CEO / Founder of MicroTechPoint Tobias Ternstrom | Microsoft SQL Server Program Manager.
SQL Data Definition Language (DDL) Using Microsoft SQL Server 1SDL Data Definition Language (DDL)
Overview · What is PL/SQL · Advantages of PL/SQL · Basic Structure of a PL/SQL Block · Procedure · Function · Anonymous Block · Types of Block · Declaring.
Chapter 5: Part 1: DDL STRUCTURED QUERY LANGUAGE (SQL)
SQL Fundamentals  SQL: Structured Query Language is a simple and powerful language used to create, access, and manipulate data and structure in the database.
Module 3 Designing and Implementing Tables. Module Overview Designing Tables Working with Schemas Creating and Altering Tables.
Chapter 8 Views and Indexes 第 8 章 视图与索引. 8.1 Virtual Views  Views:  “virtual relations”. Another class of SQL relations that do not exist physically.
Module 9: Using Advanced Techniques. Considerations for Querying Data Working with Data Types Cursors and Set-Based Queries Dynamic SQL Maintaining Query.
Module 8: Using Programming Objects for Data Retrieval.
SQL Basics Review Reviewing what we’ve learned so far…….
Module 9: Implementing Functions. Overview Creating and Using Functions Working with Functions Controlling Execution Context.
Lec-7. The IN Operator The IN operator allows you to specify multiple values in a WHERE clause. SQL IN Syntax SELECT column_name(s) FROM table_name WHERE.
In this session, you will learn to: Manage databases Manage tables Objectives.
Querying with Transact-SQL
Getting started with Accurately Storing Data
Rob Gleasure robgleasure.com
Rob Gleasure robgleasure.com
CS320 Web and Internet Programming SQL and MySQL
Module 2: Creating Data Types and Tables
Sorting and Filtering Data
10 | Programming with Transact-SQL
Introduction to Databases
Data Definition and Data Types
Module 4: Creating and Tuning Indexes
MySQL Explain examples
Microsoft SQL Server Managing Database Applications
The Ins and Outs of Partitioned Tables
මොඩියුල විශ්ලේෂණය Buffer Pool Extension භාවිතය.
Beginner Table Partitioning
Sorting and Filtering Data
DATABASE MANAGEMENT SYSTEM
STRUCTURED QUERY LANGUAGE
Lecturer: Mukhtar Mohamed Ali “Hakaale”
07 | Using Table Expressions
Introduction to partitioning
Introduction to Programming with Python
Introduction to Programming with Python
Introduction to Programming with Python
Introduction to Programming with Python
Why Should I Care About … Partitioned Views?
Customizing Views Views Customize කර ගැනීම
Using Table Expressions
Microsoft SQL Server 2014 for Oracle DBAs Module 7
MIS2502: Data Analytics SQL – Putting Information Into a Database
මොඩියුල විශ්ලේෂණය SQL Server Waits. Tables රැසක් එකට එකතු කිරීම.
Lecture 05 Views, Constraints
Rob Gleasure robgleasure.com
Table Partitioning Intro and make that a sliding window too!
CS3220 Web and Internet Programming SQL and MySQL
Table Partitioning Intro and make that a sliding window too!
Introduction to Programming with Python
Data Definition Language
Microsoft Azure Fundamentals Microsoft Azure මූලික දැනුම
Introduction to Programming with Python
Dynamic Sql Not so scary?
MIS2502: Data Analytics SQL 4– Putting Information Into a Database
මොඩියුල විශ්ලේෂණය Stored Procedure හඳුන්වා දීම.
SQL-Data Definition 4/21/2019.
CS3220 Web and Internet Programming SQL and MySQL
Structured Query Language Path from Unorganized to Organized….
Managing Table Partitions at the Extreme
Lecture 05: SQL Wednesday, October 9, 2002.
កម្មវិធីបង្រៀន SQL Programming ជាភាសាខ្មែរ Online SQL Training Course
Presentation transcript:

පාඨමාලා මාතෘකා Microsoft SQL Server Databases සැකසීම 01 | Tables සහ Views 06 | Queries Optimize සහ Troubleshoot කිරීම 02 | Indexes තේරුම් ගැනීම 03 |Stored Procedures සහ Functions භාවිතය 04 | Transactions කළමනාකරණය 05 | In-Memory Objects

SQL Server Books Online නිෂ්පාදන ලේඛන ගත කිරීම හා මග පෙන්වීම. TechNet හා MSDN හි ප්‍රකාශිතයි. ස්ථානීය අනුවාද ද ලබා ගත හැක.

MVA සමඟ එක් වන්න! Microsoft Virtual Academy IT Pros සහ Developers ලා වෙනුවෙන් සැකසුණු පාඩම් මාලා රැසක් මිලියනයකට අධික ලියාපදිංචි පරිශීලකයන් යාවත්කාලීන දැනුම් සාගරය

Prabhath Mannapperuma @dprabhathm 01 | Tables සහ Views Prabhath Mannapperuma @dprabhathm

මොඩියුල විශ්ලේෂණය Tables, Schemas සහ Views Temporary Tables සහ Table Variables Common Table Expressions Table Partitioning

Tables නිර්මාණය spaces, keywords සහ symbols අඩංගු නම් යොදා ගන්න එපා. සෑම තීරුවකම දත්ත වර්ග සැලසුම් කරන්න. Null අගයන්ට ඉඩ දෙනවා ද යන්න සැලසුම් කරන්න. primary key සහ foreign key constraints සැලසුම් කරන්න. indexes සැලසුම් කරන්න.

Tables නිර්මාණය

Schemas සමඟ වැඩ කිරීම Naming boundary Security boundary Logically group database objects Security boundary [Server.][Database.]Schema.Object GRANT EXECUTE ON SCHEMA::Sales

Default Schema සහ Name Resolution SELECT * FROM Product User 1 (Default Schema: Sales) User 3 (No Default Schema) Sales.Product dbo.Product User 2 (Default Schema: Ops) Sales Ops dbo 

Schemas සමඟ වැඩ කිරීම.

Views යනු? CREATE VIEW HumanResources.EmployeeList (EmployeeID, FamilyName, GivenName) AS SELECT EmployeeID, LastName, FirstName FROM HumanResources.Employee;

Views හඳුන්වා දීම.

Temporary Tables CREATE TABLE #tmpProducts (ProductID INTEGER, ProductName varchar(50));

Table Variables DECLARE @tmpProducts table (ProductID INTEGER, ProductName varchar(50));

Table Variables සහ Temporary Tables

Common Table Expressions WITH CTE_year AS ( SELECT YEAR(orderdate) AS orderyear, custid FROM Sales.Orders ) SELECT orderyear, COUNT(DISTINCT custid) AS cust_count FROM CTE_year GROUP BY orderyear;

Common Table Expressions

Partitioned Tables Sales.Order Filegroup 2000 Filegroup 2001 Date Order Total 20000101 123 999.99 20000105 125 287.99 Date Order Total 20010101 258 199.99 20010105 259 257.99 Date Order Total 20020101 368 199.99 20020105 369 257.99 Date Order Total 20030101 547 129.99 Filegroup 2000 Filegroup 2001 Filegroup 2002 Filegroup 2003

Creating a Partitioned Table CREATE PARTITION FUNCTION PFYears (datetime) AS RANGE RIGHT FOR VALUES (20000101, 20010101, 20020101); --creates 4 partitions: -- <-2000, 2000-2001, 2001-2002, 2002-> CREATE PARTITION SCHEME PSYears AS PARTITION PFYears TO (FG0000, FG2000, FG2001, FG2002, FG2003); -- FG2003 is marked as ‘next used’ CREATE TABLE Sales.Order (OrderDate datetime, OrderNo int, Customer varchar(50), OrderAmount money) ON PSYears(OrderYear);

Partitioned Tables කළමනාකරණය Split Partitions Merge Partitions Switch Partitions -- Create a new partition for 2003 orders -- (created on next used filegroup) ALTER PARTITION FUNCTION PFYears() SPLIT RANGE (20030101); -- Merge 2000 and pre-2000 orders ALTER PARTITION FUNCTION PFYears() MERGE RANGE (20000101); -- Switch partition containing old orders -- to a staging table for archiving ALTER TABLE Sales.Order SWITCH PARTITION $PARTITION.PFYears(20000101) TO archive_staging_table;

Table Partitioning

Tables සහ Views සම්පිණ්ඩනය Tables Schemas Views Temporary Tables Table Variables Common Table Expressions Partitioned Tables