By: Matt Batalon, MCITP  Another form of temporary storage that can be queried or joined against, much like a table variable, temp.

Slides:



Advertisements
Similar presentations
Yukon – What is New Rajesh Gala. Yukon – What is new.NET Framework Programming Data Types Exception Handling Batches Databases Database Engine Administration.
Advertisements

Virtual training week 4 structured query language (SQL)
PHP (2) – Functions, Arrays, Databases, and sessions.
A Guide to Oracle9i1 Advanced SQL And PL/SQL Topics Chapter 9.
Copyright س Oracle Corporation, All rights reserved. 13 Other Database Objects.
Chapter 7 Managing Data Sources. ASP.NET 2.0, Third Edition2.
RIZWAN REHMAN, CCS, DU. Advantages of ORDBMSs  The main advantages of extending the relational data model come from reuse and sharing.  Reuse comes.
SEMESTER 1, 2013/2014 DB2 APPLICATION DEVELOPMENT OVERVIEW.
Module 9: Managing Schema Objects. Overview Naming guidelines for identifiers in schema object definitions Storage and structure of schema objects Implementing.
Database Design for DNN Developers Sebastian Leupold.
Native Support for Web Services  Native Web services access  Enables cross platform interoperability  Reduces middle-tier dependency (no IIS)  Simplifies.
SQL Server 2008 for Developers John
Database Technical Session By: Prof. Adarsh Patel.
ADO.NET A2 Teacher Up skilling LECTURE 3. What’s to come today? ADO.NET What is ADO.NET? ADO.NET Objects SqlConnection SqlCommand SqlDataReader DataSet.
Lecture Set 14 B new Introduction to Databases - Database Processing: The Connected Model (Using DataReaders)
MySQL Databases & PHP Integration Using PHP to write data to, and retrieve data from, a MySQL database.
5/24/01 Leveraging SQL Server 2000 in ColdFusion Applications December 9, 2003 Chris Lomvardias SRA International
1 Copyright © 2004, Oracle. All rights reserved. Introduction.
Controlling User Access. Objectives After completing this lesson, you should be able to do the following: Create users Create roles to ease setup and.
Stored Procedures Week 9. Test Details Stored Procedures SQL can call code written in iSeries High Level Languages –Called stored procedures SQL has.
Lecture Set 14 B new Introduction to Databases - Database Processing: The Connected Model (Using DataReaders)
Sumanth M Ganesh B CPSC 620.  SQL Injection attacks allow a malicious individual to execute arbitrary SQL code on your server  The attack could involve.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Information Building and Retrieval Using MySQL Track 3 : Basic Course in Database.
SQL Fundamentals  SQL: Structured Query Language is a simple and powerful language used to create, access, and manipulate data and structure in the database.
Controlling User Access Fresher Learning Program January, 2012.
What is a Package? A package is an Oracle object, which holds other objects within it. Objects commonly held within a package are procedures, functions,
Visual Programing SQL Overview Section 1.
Indexes and Views Unit 7.
Variables and control statements in PL\SQL Chapter 10.
Chapter 13 Views Oracle 10g: SQL. Oracle 10g: SQL2 Objectives Create a view, using CREATE VIEW command or the CREATE OR REPLACE VIEW command Employ the.
SQL.. AN OVERVIEW lecture3 1. Overview of SQL 2  Query: allow questions to be asked of the data and display only the information required. It can include.
Chapter 4 Indexes. Indexes Logically represents subsets of data from one or more tables View Generates numeric valuesSequence Basic unit of storage; composed.
Learningcomputer.com SQL Server 2008 –Views, Functions and Stored Procedures.
Stored Procedures / Session 4/ 1 of 41 Session 4 Module 7: Introducing stored procedures Module 8: More about stored procedures.
SQL Query Analyzer. Graphical tool that allows you to:  Create queries and other SQL scripts and execute them against SQL Server databases. (Query window)
1 A Very Brief Introduction to Relational Databases.
Module 10 Merging Data and Passing Tables. Module Overview Using the MERGE Statement Implementing Table Types Using Table Types As Parameters.
SSMS SQL Server Management System. SQL Server Microsoft SQL Server is a Relational Database Management System (RDBMS) Relational Database Management System.
SQL Triggers, Functions & Stored Procedures Programming Operations.
 CONACT UC:  Magnific training   
Create Stored Procedures and Functions Database Management Fundamentals LESSON 2.4.
SQL Basics Review Reviewing what we’ve learned so far…….
Dynamic SQL Writing Efficient Queries on the Fly ED POLLACK AUTOTASK CORPORATION DATABASE OPTIMIZATION ENGINEER.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 Using Stored Procedures ADO.NET - Lesson 07  Training time: 15 minutes  Author:
Views / Session 3/ 1 of 40 Session 3 Module 5: Implementing Views Module 6: Managing Views.
1 c6212 Advanced Database and Client Server MS SQL Server 2000 Stored Procedures and Parameters What ? Why ? How ?
Fundamental of Database Systems
Dynamic SQL Writing Efficient Queries on the Fly
Stored Procedures.
© 2016, Mike Murach & Associates, Inc.
SQL Creating and Managing Tables
Dynamic SQL: Writing Efficient Queries on the Fly
UNIT - V STORED PROCEDURE.
Optimizing Microsoft SQL Server 2008 Applications Using Table Valued Parameters, XML, and MERGE
DATABASE MANAGEMENT SYSTEM
SQL Creating and Managing Tables
Agenda Database Development – Best Practices Why Performance Matters ?
PRACTICE OVERVIEW PL/SQL Part - 2.
U-SQL Object Model.
Database.
SQL Creating and Managing Tables
Chapter 4 Indexes.
CH 4 Indexes.
Dynamic SQL: Writing Efficient Queries on the Fly
CH 4 Indexes.
SQL .. An overview lecture3.
Relational Database Design
Chapter 8 Advanced SQL.
SQL Server Query Design and Optimization Recommendations
Presentation transcript:

By: Matt Batalon, MCITP

 Another form of temporary storage that can be queried or joined against, much like a table variable, temp table or CTE  Based on user defined table type that describes schema for a table  Commonly referred to as Table Valued Parameters (TVP) or User Defined Table Types

 Can be passed as a single parameter (set of rows) to a stored procedure or user defined function unlike a table variable or temp table  Can be passed between stored procedures or from client side application  Reusability; the schema for a TVP is centrally maintained

 TVP types are displayed in SQL Server Management Studio unless manually dropped  Programmability  Types  User Defined Table Types  Can expand to see columns, constraints, indexes

 Ease of encapsulating multiple parameters into a single parameter  Reduces round trips to the server, which can aid in performance  Strongly typed with the CREATE TYPE…TABLE statement  Easily maintainable code because schema can be defined only once then can be reused

 Forced to send multiple parameters as arguments  Use String Manipulation to encapsulate multiple parameters  Individual Database calls, not a set based approach

 Using a TVP vs. Delimited String  Bulk inserting a TVP  Bulk Update using a TVP  Encapsulate business logic using TVPs, and reducing round trips to server

 Data cannot be modified, must be passed as READ ONLY  Cannot use ALTER table statement on a TVP, must be dropped and recreated  No support for Select INTO or INSERT Exec statement

 Books online ◦ Examples for using with ADO.net ◦ Comparison with BCP ◦ Connectivity Books : Programming SQL Server 2008 by Leonard Lobel, Andrew Bust, Stephen Forte