 What is DB Testing ?  Testing at the Data Access Layer  Need for Testing DB Objects  Common Problems that affect the Application  Should Testers.

Slides:



Advertisements
Similar presentations
Chapter 10: Designing Databases
Advertisements

C6 Databases.
Accounting System Design
ASP.NET Database Connectivity I. 2 © UW Business School, University of Washington 2004 Outline Database Concepts SQL ASP.NET Database Connectivity.
Chapter 11 Data Management Layer Design
SQL Table Basics. Database Objects Tables Temporary tables (begin with #) Views Keys Indexes.
Introduction to Structured Query Language (SQL)
INTEGRITY Enforcing integrity in Oracle. Oracle Tables mrobbert owner granted access.
1 Nassau Community CollegeProf. Vincent Costa Acknowledgements: Introduction to Database Management, All Rights ReservedIntroduction to Database Management.
Data at the Core of the Enterprise. Objectives  Define of database systems  Introduce data modeling and SQL  Discuss emerging requirements of database.
DAT702.  Standard Query Language  Ability to access and manipulate databases ◦ Retrieve data ◦ Insert, delete, update records ◦ Create and set permissions.
Chapter 9: Creating Database Conventions & Standards MCITP Administrator: Microsoft SQL Server 2005 Database Server Infrastructure Design Study Guide (70-443)
Phil Brewster  One of the first steps – identify the proper data types  Decide how data (in columns) should be stored and used.
IST Databases and DBMSs Todd S. Bacastow January 2005.
Database Lecture # 1 By Ubaid Ullah.
Data at the Core of the Enterprise. Objectives  Define of database systems.  Introduce data modeling and SQL.  Discuss emerging requirements of database.
5.1 © 2007 by Prentice Hall 5 Chapter Foundations of Business Intelligence: Databases and Information Management.
Database Design for DNN Developers Sebastian Leupold.
Your Interactive Guide to the Digital World Discovering Computers 2012.
ASP.NET Programming with C# and SQL Server First Edition
Web Application Development. Define ER model in QSEE Generate SQL Create Database mySQL Write Script to use TableEditor class Process to create A simple.
Web Application Development. Tools to create a simple web- editable database QSEE MySQL (or PHPMyAdmin) PHP TableEditor.
DataBase Testing. Objectives What is DB Testing ? Testing at the Data Access Layer Scope of DB Testing Need for Testing DB Objects Common Problems that.
An Investigation of Oracle and SQL Server with respect to Integrity, and SQL Language standards Presented by: Paul Tarwireyi Supervisor: John Ebden Date:
Database Technical Session By: Prof. Adarsh Patel.
Chapter 1 In-lab Quiz Next week
DATABASES Pindaro Demertzoglou – Lally School of Management and Technology.
CPS120: Introduction to Computer Science Lecture 19 Introduction to SQL.
Lecturer: Gareth Jones. How does a relational database organise data? What are the principles of a database management system? What are the principal.
Lecture2: Database Environment Prepared by L. Nouf Almujally & Aisha AlArfaj 1 Ref. Chapter2 College of Computer and Information Sciences - Information.
SQL SQL Server : Overview SQL : Overview Types of SQL Database : Creation Tables : Creation & Manipulation Data : Creation & Manipulation Data : Retrieving.
Oracle Data Integrator Transformations: Adding More Complexity
7 1 Chapter 7 Introduction to Structured Query Language (SQL) Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel.
C6 Databases. 2 Traditional file environment Data Redundancy and Inconsistency: –Data redundancy: The presence of duplicate data in multiple data files.
Application Data and Database Activities Auditing Dr. Gabriel.
Christopher M. Pascucci.NET Programming: Databases & ADO.NET.
6.1 © 2010 by Prentice Hall 6 Chapter Foundations of Business Intelligence: Databases and Information Management.
MANAGING DATA RESOURCES ~ pertemuan 7 ~ Oleh: Ir. Abdul Hayat, MTI.
1 CSE 2337 Introduction to Data Management Access Book – Ch 1.
Data Driven Designs 99% of enterprise applications operate on database data or at least interface databases. Most common DBMS are Microsoft SQL Server,
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Indexes / Session 2/ 1 of 36 Session 2 Module 3: Types of Indexes Module 4: Maintaining Indexes.
SQL Server 2005 Implementation and Maintenance Chapter 3: Tables and Views.
Database Fundamental & Design by A.Surasit Samaisut Copyrights : All Rights Reserved.
Visual Programing SQL Overview Section 1.
Foundations of Business Intelligence: Databases and Information Management.
Physical Database Design Purpose- translate the logical description of data into the technical specifications for storing and retrieving data Goal - create.
Session 1 Module 1: Introduction to Data Integrity
>> Introduction to MySQL. Introduction Structured Query Language (SQL) – Standard Database Language – Manage Data in a DBMS (Database Management System)
Relational Database Management System(RDBMS) Structured Query Language(SQL)
Starting with Oracle SQL Plus. Today in the lab… Connect to SQL Plus – your schema. Set up two tables. Find the tables in the catalog. Insert four rows.
IMS 4212: Constraints & Triggers 1 Dr. Lawrence West, Management Dept., University of Central Florida Stored Procedures in SQL Server.
Introduction to Core Database Concepts Getting started with Databases and Structure Query Language (SQL)
Data Resource Management Application Layer TPS A RCHITECTURE Data Layer Sales/MarketingHR Finance/Accounting Operations Spreadsheet Data MS Access Accounts.
MySQL Tutorial. Databases A database is a container that groups together a series of tables within a single structure Each database can contain 1 or more.
SQL Basics Review Reviewing what we’ve learned so far…….
In this session, you will learn to: Manage databases Manage tables Objectives.
Agenda for Today  DATABASE Definition What is DBMS? Types Of Database Most Popular Primary Database  SQL Definition What is SQL Server? Versions Of SQL.
Data Integrity & Indexes / Session 1/ 1 of 37 Session 1 Module 1: Introduction to Data Integrity Module 2: Introduction to Indexes.
Understanding Core Database Concepts Lesson 1. Objectives.
Getting started with Accurately Storing Data
Databases and DBMSs Todd S. Bacastow January
Managing Tables, Data Integrity, Constraints by Adrienne Watt
The Client/Server Database Environment
Accounting System Design
MANAGING DATA RESOURCES
Accounting System Design
Relational Database Design
Indexes and more Table Creation
Understanding Core Database Concepts
Presentation transcript:

 What is DB Testing ?  Testing at the Data Access Layer  Need for Testing DB Objects  Common Problems that affect the Application  Should Testers Know Databases  Writing Test Cases to Test Databases  Testing Tools  Examples

 Database Testing includes Testing for Data Integrity, Data Validity, Data manipulation.  Database Objects can be tables, views, stored procedures, indexes etc  Time taken for Retrieval of Records from the Database  Time for Query Execution

 Client Layer – Is responsible for the presentation of data, receiving user events and controlling the user interface.  Application Layer - Business-objects that implement the business rules "live" here, and are available to the client-tier  Data Layer : This tier is responsible for data storage

 Testing the Front End / GUI / Client Layer  Testing the Business Logic Layer  Testing the Database  Reviewing E/R Diagrams  Reviewing the Database Designs  Reviewing the Tables, views, stored procedures etc

 Data is stored in the tables  Stored Procedures will handle the Insertion, deletion & Updation & Retrieval of Information from the Database  No Testing/Improper testing will result in missing critical application functionality

 Traditionally all the data testing is done at the GUI Level  Corruption of data can occur at any layer  We must present verification of application correctness as data travels through the system.

 Data corruption  Occurs due to poor design  Redundant data  Hidden duplicate records (same customer added twice with different primary keys).  Inconsistent data  Data records added to the same database through multiple applications can add inconsistent data.

 Validate the table naming conventions  Validate the column naming conventions  To check if the correct datatype is selected for a column  To check the consistency in datatypes for columns common across tables  To ensure the usage of correct field width

 To ensure consistency in field width for columns common across tables  Existence of a primary key on a table  Existence of a foreign key on a table  Validity of check constraints  Validity of default constraints  Check for presence of indexes on a column

 Check for Unique indexes  Existence of non-clustered indexes  Existence of clustered indexes  Note the time of execution of queries  Note the time of compilation of queries

 Evaluate the query execution plan  Note the time of execution of stored procedures  Note the time of compilation of stored procedures  Evaluate the query execution plan  Denormalize the tables  Normalize the tables

SQL TunerSQL Tuner : Embaradero Eases the complexity of writing high-performance SQL code by providing built-in help for writing syntactically correct SQL, and by assisting in every aspect of complex tuning efforts.

Datatect Datatect : Banner Software Generate a variety of realistic test data to RDBMS including Oracle, Sybase, SQL Server, and Informix DB Stress DB Stress : Utility for stress testing the server parts of information systems and applications, as well as DBMSs and servers themselves.

 Database Opensource Test Suite  The Database Opensource Test Suite (DOTS) is a set of test cases designed for the purpose of stress-testing database server systems in order to measure database server performance and reliability.

 DBMonster  DBMonster is an application to generate random data for testing SQL database driven applications under heavy load.

[Test] public void ColumnTypeIsNotDeprecated() { const string cmdText t.name AS tableName, c.name AS columnName, ty.name AS columnType FROM sys.tables t JOIN sys.columns c ON c.object_id = t.object_id JOIN sys.types ty ON ty.system_type_id = c.system_type_id AND ty.user_type_id = c.user_type_id WHERE ty.name = 'text' OR ty.name = 'ntext' OR ty.name = 'image' OR ty.name = 'datetime'";. Assert.That(deprecatedColumns, Is.Empty, "Column types are deprecated (text, ntext, image, datetime). Use varchar(max), nvarchar(max), varbinary(max) and datetime2(0) instead."); }

ALTER PROCEDURE TryItOut. AS BEGIN INT; = 1 + 2; EXEC tSQLt.AssertEquals END GO Video: WzcFz0 (tsSQLt) WzcFz0

 What Database Testing includes?  What Database Objects can by tested?  How many layers exists in a Application?  What pproblems can happened if Database Testing is Ignored?  What we can Test at the DB Level? (Min 3)