Confidencial - TRACASA Automatize test [e- Reporting]

Slides:



Advertisements
Similar presentations
CC SQL Utilities.
Advertisements

Module 17 Tracing Access to SQL Server 2008 R2. Module Overview Capturing Activity using SQL Server Profiler Improving Performance with the Database Engine.
Moving Data Lesson 23. Skills Matrix Moving Data When populating tables by inserting data, you will discover that data can come from various sources.
ERWin Template Overview By: Dave Wentzel. Agenda u Overview of Templates/Macros u Template editor u Available templates u Independent column browser u.
Advantage Data Dictionary. agenda Creating and Managing Data Dictionaries –Tables, Indexes, Fields, and Triggers –Defining Referential Integrity –Defining.
Introduction to Structured Query Language (SQL)
Let’s try Oracle. Accessing Oracle The Oracle system, like the SQL Server system, is client / server. For SQL Server, –the client is the Query Analyser.
Quick-and-dirty.  Commands end in a semi-colon ◦ If you forget, another prompt line shows up  Either continue the command or…  End it with a semi-colon.
Introduction to Structured Query Language (SQL)
Fundamentals, Design, and Implementation, 9/e Chapter 11 Managing Databases with SQL Server 2000.
A Guide to SQL, Seventh Edition. Objectives Understand the concepts and terminology associated with relational databases Create and run SQL commands in.
Introduction to Structured Query Language (SQL)
A Guide to MySQL 3. 2 Objectives Start MySQL and learn how to use the MySQL Reference Manual Create a database Change (activate) a database Create tables.
Tutorial 11: Connecting to External Data
1 Chapter Overview Transferring and Transforming Data Introducing Microsoft Data Transformation Services (DTS) Transferring and Transforming Data with.
DB Audit Expert v1.1 for Oracle Copyright © SoftTree Technologies, Inc. This presentation is for DB Audit Expert for Oracle version 1.1 which.
Advance Computer Programming Java Database Connectivity (JDBC) – In order to connect a Java application to a database, you need to use a JDBC driver. –
A Guide to SQL, Eighth Edition Chapter Three Creating Tables.
Agenda Journalling More Embedded SQL. Journalling.
Creating Data Marts from COBOL Files (ISAM to RDBMS)
Functions Lesson 10. Skills Matrix Function A function is a piece of code or routine that accepts parameters and stored as an object in SQL Server. The.
What is Sure BDCs? BDC stands for Batch Data Communication and is also known as Batch Input. It is a technique for mass input of data into SAP by simulating.
UNIT TESTING FOR SQL Prepared for SUGSA CodeLabs Alain King Paul Johnson.
Working with Reports in Microsoft Excel Session Version 1.0 © 2011 Aptech Limited.
Exploring Microsoft Office XP - Microsoft Word 2002 Chapter 71 Exploring Microsoft Word Chapter 7 The Expert User: Workgroups, Forms, Master Documents,
IT 456 Seminar 5 Dr Jeffrey A Robinson. Overview of Course Week 1 – Introduction Week 2 – Installation of SQL and management Tools Week 3 - Creating and.
Overview · What is PL/SQL · Advantages of PL/SQL · Basic Structure of a PL/SQL Block · Procedure · Function · Anonymous Block · Types of Block · Declaring.
Siebel 8.0 Module 5: EIM Processing Integrating Siebel Applications.
Oracle Data Integrator Procedures, Advanced Workflows.
Understanding SQL Server 2008 Change Data Capture Bret Stateham Training Manager Vortex Learning Solutions blogs.netconnex.com.
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.
Database Design and Management CPTG /23/2015Chapter 12 of 38 Functions of a Database Store data Store data School: student records, class schedules,
1 Chapter Overview Preparing to Upgrade Performing a Version Upgrade from Microsoft SQL Server 7.0 Performing an Online Database Upgrade from SQL Server.
A Brief Documentation.  Provides basic information about connection, server, and client.
6 1 Lecture 8: Introduction to Structured Query Language (SQL) J. S. Chou, P.E., Ph.D.
SQL Injection Jason Dunn. SQL Overview Structured Query Language For use with Databases Purpose is to retrieve information Main Statements Select Insert.
A Guide to MySQL 3. 2 Introduction  Structured Query Language (SQL): Popular and widely used language for retrieving and manipulating database data Developed.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
SQL Fundamentals  SQL: Structured Query Language is a simple and powerful language used to create, access, and manipulate data and structure in the database.
06 | Modifying Data in SQL Server Brian Alderman | MCT, CEO / Founder of MicroTechPoint Tobias Ternstrom | Microsoft SQL Server Program Manager.
Oracle Data Integrator Data Quality (Integrity Control)
MySQL and GRID status Gabriele Carcassi 9 September 2002.
Constraints Lesson 8. Skills Matrix Constraints Domain Integrity: A domain refers to a column in a table. Domain integrity includes data types, rules,
Task #1 Create a relational database on computers in computer classroom 308, using MySQL server and any client. Create the same database, using MS Access.
Learningcomputer.com SQL Server 2008 –Views, Functions and Stored Procedures.
CPSC 203 Introduction to Computers T97 By Jie (Jeff) Gao.
A Guide to SQL, Eighth Edition Chapter Six Updating Data.
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.
SQL Query Analyzer. Graphical tool that allows you to:  Create queries and other SQL scripts and execute them against SQL Server databases. (Query window)
Oracle Business Intelligence Foundation – Testing and Deploying OBI Repository.
Module 2: Authoring Basic Reports. Overview Creating a Basic Table Report Formatting Report Pages Calculating Values.
5 Copyright © 2008, Oracle. All rights reserved. Testing and Validating a Repository.
LM 5 Introduction to SQL MISM 4135 Instructor: Dr. Lei Li.
SQL Triggers, Functions & Stored Procedures Programming Operations.
 CONACT UC:  Magnific training   
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.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe.
Views / Session 3/ 1 of 40 Session 3 Module 5: Implementing Views Module 6: Managing Views.
2 Copyright © 2008, Oracle. All rights reserved. Building the Physical Layer of a Repository.
DbFit for FitNesse with Data Warehouse worked examples Chris SAUNDERS - September 2014 [AdventureWorks2014] Source Data (multiple.
3 A Guide to MySQL.
Query Methods Simple SQL Statements Start ….
CS320 Web and Internet Programming SQL and MySQL
Lecture Set 14 B new Introduction to Databases - Database Processing: The Connected Model (Using DataReaders)
Introduction To Structured Query Language (SQL)
Introduction To Structured Query Language (SQL)
Contents Preface I Introduction Lesson Objectives I-2
Presentation transcript:

Confidencial - TRACASA Automatize test [e- Reporting]

Confidencial - TRACASA INTRODUCTION  Data loading procedure is time consuming and complex  Aggregate calculation procedures are time- consuming and complex  Testing (even small) changes or new features in both procedures is time-consuming and tedious 2

Confidencial - TRACASA OBJECTIVE  Create automate testing in order to reduce  Bugs in data loading and aggregate calculations procedures  Facilitate data error detection  Reduce man power needed in these tasks 3

Confidencial - TRACASA APPROACH  Generic  Based on well-known best practices  Use of simple procedures and a structure capable of validating everything related to a SQL relational database: database existence, users, schema, data, results in a view, stored procedures,...  Anything included in a valid SELECT statement  Simple and understandable  An SQL test database with 3 tables and a generic store procedure  One of the tables storing a list of all "test cases" and the expected result  Each "test case" will test a requirement included in SELECT statement that must return maximum one row and one column  Multidatabase  The test cases can be launched against any database hosted in the same server as the SQL test database 4

Confidencial - TRACASA TEST TABLE STRUCTURE 5  Test_Plan  Table to store high level groups of test suits (Deployment version, FME data loading, Aggregate calculations and any other system that needs testing)  Test_Suite  Table to store for each [Test_Plan] groups of test cases  Test_Case  Table to store for each [Test_Suite], a specific unit validation Explained in more detail in the following slides

Confidencial - TRACASA Test_Plan 6 [definition]:Descriptive text [filter]: Optional text used to filter tests to execute. Each filter must be between the character ‘|’. e.g. |FME|deploy|

Confidencial - TRACASA Test_Suite 7 [definition]:Descriptive text [filter]: Optional text used to filter tests to execute. Each filter must be between the character ‘|’. e.g. |Load|Update|

Confidencial - TRACASA Test_Case 8 [definition]:Descriptive text [filter]: Optional text used to filter tests to execute. Each filter must be between the character ‘|’. e.g. |SP|Function|Index| [order_exec]: Integer to specify the execution sequence. Also to make the tests groupable [sql]: Text with t-sql command to execute. The sentence must return only one value which alias should be 'expectedresult‘ e.g. SELECT 1 AS expectedresult e.g. SELECT TOP 1 [field] AS expectedresult FROM [dbo].[table] [expectedresult]: Result expected from the sql statement

Confidencial - TRACASA HOW TO EXECUTE A TEST 9  The test database includes a general Stored Procedure [Exec_TestSuit]  Input parameters of the exec: name of the database which will be tested ID of the test suit. (optional) By default Null. Otherwise, filter the [Test_Case] where [filter] e.g. EXEC = = = Null; e.g. EXEC = = = ‘FME’; -- execute only the [test_case] where filter is like ‘|FME|’

Confidencial - TRACASA AIRQUALITY TESTS APPROACH  Design  Isolated test environment  Workflow including unattended test procedures  Setup  Implement empty test database  Identify, gather and store relevant and applicable data samples in files  Prepare and implement relevant queries to test procedures  Prepare cleaning test environment procedure 10

Confidencial - TRACASA AIRQUALITY TEST WORKFLOW 11 Initialize Environment Tests should always start from same starting point. Initial Test Check the database deployment before testing routines First Load (*) FME: Only Insert new data Agg: First generation Load = 1 Insert & Update (*) FME: Insert and update Agg: Generate again Load = 2 Insert & Update XX (*) FME: Insert and update Agg: Generate again Load = XX

Confidencial - TRACASA INSERT & UPDATE XX PROCESS DETAILED 12 FME Load Load a XML from UTD or CDR Workbench for metadata ‘D’ Workbench for measures ‘E’ Test FME Load Validate the Insert/Update in ‘D’ and ‘E’ SQL Job Aggregations Calculate the Agg. with the new delivery Test Aggregations Validate the result of the Aggregates

Confidencial - TRACASA AIRQUALITY TESTS IMPLEMENTATION 13  To ease the tests execution, three stored procedures has been created:  AQ_00_Deploy: to check database schema and master data  AQ_01_FME_Load: to check FME Load process  AQ_02_AGG_Load: to check Aggregates process  These three execute the general Stored Procedure [Exec_TestSuit] with specific parameters

Confidencial - TRACASA INITIALIZE ENVIROMENT 14  Environment under control  Restricted access  Manual process to:  Initialize the database to a clean status (tests should always start from same starting point)  Restore database or execute scripts to delete all data and restart the identity values e.g.: ‘AQ_clean_database_initial_state.sql’ Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA INITIAL TEST 15  Execute AQ_00_Deploy to validate database deployment and specifically correctness of before testing process:  Stored procedures, indexes, functions, table structure, master data (eg: records in Unit table, timezone in AggregateType table…) USE [Test_SQL] GO EXEC = = NULL Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA First Load - FME 16  Use specific XML files to load for the first time well known data  Launch the FME Load ‘0_Main.fmw’ to fill the metadata (D)  Launch the FME Load ‘E_Batch_Workbench.fmw’ to fill the measurements (E) Test with AQ_01_FME_Load (test cases not implemented yet) USE [Test_SQL] GO EXEC = = = NULL Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA First Load - AGGREGATES 17  Launch aggregates calculations procedures Test with AQ_02_AGG_Load USE [Test_SQL] GO EXEC = = = NULL Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA INSERT & UPDATE - FME 18  Use specific XML files to update and/or insert new well known data  Launch the FME Load ‘0_Main.fmw’ to fill the metadata (D)  Launch the FME Load ‘E_Batch_Workbench.fmw’ to fill the measurements (E) Test with AQ_01_FME_Load (test cases not implemented yet) USE [Test_SQL] GO EXEC = = = NULL Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA INSERT & UPDATE - AGGREGATES 19  Launch aggregates calculations procedures  Test aggregates calculations procedures USE [Test_SQL] GO EXEC = = = NULL Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA REPEAT 20  Loop through Load procedures, testing new updates and inserts using different data files and test all the casuistic as many times as needed to have a comprehensive testing Full workflow Workflow of each “Insert & Update XX” Overview

Confidencial - TRACASA KEEP IN MIND 21  When new features or changes are implemented in the Load or Aggregations procedures:  Check if tests cases are still valid or need changes  Check if new test cases are needed

Confidencial - TRACASA By David Alonso