Académique Documents
Professionnel Documents
Culture Documents
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
1/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
table
contains
primary
key
and
non-quantifying
columns. If the primary key does not exist in source table then
surrogate key would exist.
What are the types of dimension?
Based on what type of data it stores there is two major types dimension
table,
1.Conrmed dimension
2.Junk dimension
Based on where its being derived there is one dimension category,
3.Degenerated dimension
Based on how frequently the data in the dimension can be divided into
2 types,
4.Rapidly Changing Dimension (RCD)
5.Slowly Changing Dimension (SCD)
What is a fact and what are the types of fact?
A fact is a column or attribute which can be quantiable or measurable
and will be used as key analysis factor. We can call it as a measure.
Types of Fact:
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
2/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
1. Additive
2. Semi-additive
3. Non-additive
What does a fact table contain?
A table which contains facts is called fact table. Typically a fact table
has facts and foreign keys of dimension tables.
Fact table structure:
Foriegn_key1
Forign_keyN
Fact1
FactN
What are the types of a fact table?
Transactional
The fact table will contain datas in very detail level without any
rollup/aggregation the way how transactional database stores.
Accumulating
Accumulating refers storing multiple entries for a single record to
track the changes throughout the workow.
Periodic snapshot
The data will be extracted and loaded for a particular period of a time.
It describes what would be the state of the record in that specic
period.
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
3/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
4/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
application
applications
(Select/Insert/Update/Delete)
The main purpose is for using day to
day transactions
Factor
Period
ODS
It will have limited period of
data (30 to 90 days)
Staging
Based on type of load it stores
incremental data or full volume
of data
Temporary data storage and for
Purpose
Operational processing
Data
5/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Feature
Performance
Query
complexity
Star Schema
Snowake schema
As there is no relationship
between dimensions to
between dimensions
be low.
Database size
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
6/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Normalization
more normalized
normalized format in
format in dimension
dimension table
tables
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
7/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
8/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
9/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Active Transformation
The output record count of the transformation may or may not
equalto input record count.
For example, when we apply lter transformation for age column
with the condition of age between 25 and 40. In this case, the data
will come out which satises this condition, hence the outcome
count cannot be predicted.
Passive Transformation
The output record count of the transformation isequal to inputrecord
count.
For
example,
when
we
apply
expression
transformation
to
concatenate rst name and last name columns, in this case, the data
will come out even though the columns do not have values.
Connected Transformation
A transformation which is being linked with other transformation or
target component is called connected.
Unconnected Transformation
A transformation which is not being linked with any other
transformation or target component is called unconnected.
What are the types of load?
Full Load(Initial Load or Bulk Load or Fresh Load)
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
10/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
11/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
12/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
UsingAutomationtoolstoolwillfetchdataandcomparesinternallywithown
algorithm
Using utility tools develop an automation utility tool using Java or any
scriptinglanguagealongwithdatabasedrivers
Give an example for Low severity and High priority defect.
-There is a requirement where email notication needs to be
triggered in case of job failure
-There is a deviation found during testing that the email notication
has been received but the number of records count in the content is
not matching
Low severity since it does not aect any functionality
High priority since the wrong data count shows the wrong
picture to the management team
What are the components of Informatica?
One of the major tool in worldwide. Majorly this tool is using for
ETL, data masking, and data quality.
It has four major components,
1. Repository manager to add repository and managing folders
2. Designer creating mappings
3. Workow manager creating workow with task and mappings
4. Workow monitor workow run status tracker
What are tasks available in Informatica?
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
13/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
The below are major tasks available in Informatica power center tool.
1.Session
2.Email
3.Command
4.Control
5.Decision
6.Timer
Database testing vs ETL testing
ETL Testing Making sure that the data from source to target is
being loaded properly or not along with the business transformation
rules.
Database Testing Testing whether the data is being stored properly
in the database when we do some operations from the front end or
back end along with testing of procedures, functions, and triggers.
Testing whether the data is being retrieved properlyin UI.
What is partitioning?
Portioning is a concept of running with parallel threads by distributing
records. It will be used when the volume of data is huge which
directly impact the data load and other transformation progress.
Database and ETL tools are oering this partition concept to
improvise the job execution time for high volume data tables.
Below are the types of partitioning available in Informatica power
center tool,
1.Pass Through
2.Database partitioning
3.Key range
4.Round robin
5.Hash Auto key
6.Has user key
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
14/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
15/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Running job with bad data does not kick o the bad datas
properly
Rollback is not happening in case of job failure
Performance issue
Log le and content issue
Mail notication and content issue
1000 records are in the source table, but only 900 records are loaded
into the target table. How do you nd the missing 100 records?
UsingSEToperatorMINUSifbothsourceandtargettablesareinthesame
databaseserver.
UsingExcel macro both source table and target table data will be copied
intoanexcelandcomparedwithmacro
Using Automation tool tool will fetch data and compares internally with
ownalgorithm
Using Utility tool develop an automation utility tool using Java or any
scriptinglanguagealongwithdatabasedrivers
Can you give few test cases to test the incremental load table?
Insert few records and validate the data after job run
Update non-primary column values and validate the data after job
run
Update primary column values and validate the data after job run
Delete few records and validate the data after job run
Insert/update few records to create duplicate entries and validate
the data after job run
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
16/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Update with bad data NULL values, blank spaces, lookup data
missing
How do you compare a at le and database table?
-Manual Sampling method manually comparedin sampling basis
UsingExcelmacroflatfiledataandtargettabledatawillbecopiedintoan
excelandcomparedwithmacro
Using Automation tool tool will fetch data and compares internally with
ownalgorithm
Using Utility tool develop an automation utility tool using Java or any
scriptinglanguagealongwithdatabasedrivers
id
Name
Country
DOB
Bala
India
25-JAN-1987
Krishnan
India
01-NOV-1992
Test
India
14-JUL-1989
Bala
India
25-JAN-1987
Using GROUP BY
SELECT name, count(*)
FROM employee
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
17/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
GROUP BY name
HAVING count(*)>1;
Using Rank()
SELECT *
FROM (
SELECT name, RANK() over(PARTITION BY name ORDER BY id) as
rankn
FROM employee)
WHERE rankn>1;
Using Rownum()
SELECT *
FROM (
SELECT name, rownum() over(PARTITION BY name ORDER BY id) as
rowno
FROM employee)
WHERE rowno >1;
Using GROUP BY
DELETE FROM employee
WHERE rowid IN (
SELECT rowid
FROM employee
GROUP BY name
HAVING COUNT(*)>1);
Using Rank()
DELETE FROM employee
WHERE rowid IN (
SELECT rowid FROM(
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
18/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Scenario
Purpose
Can rollback
DML/DDL/D
CL
Delete
Truncate
Yes
No
No
DML
DML
DDL
Drop
Remove the table
itself from
database
Faster since it
Faster
removes table
irrespective if
data volume
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
19/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Activity
Number of
columns in a
table
Primary Key
Foreign Key
have
have
Allows NULL values
NULL insert
Allows
duplicate
No
Yes
values
20/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
EmpId
Month
Salary
1001
10000
1002
12000
1003
10000
1004
12000
Select
empid, month, salary, sum(salary) over (order by empid, month
ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) cum_salary
From Salary
Group by empid, month, salary
Order by empid, month
EmpId
Month
Salary
cum_salary
1001
10000
10000
1002
12000
22000
1003
10000
32000
1004
12000
44000
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
21/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Select
id,name,dept,salary,
DENSE_RANK () over(PARTITION BY dept ORDER BY salary desc) as
rankorder
from employee
order by dept,rankorder
id
name
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
dept
salary
22/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
1009
TECH
900000
1006
TECH
800000
1005
QA
700000
1008
QA
700000
1010
QA
600000
id
name
dept
salary
Rank
Dense_rank
1009
TECH
900000
1006
TECH
800000
1005
QA
700000
1008
QA
700000
1010
QA
600000
23/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Activity
Number of
columns in a
table
Primary Key
Foreign Key
have
have
Allows NULL values
NULL insert
Allows
duplicate
No
Yes
values
Subquery vs Join?
-The columns of subquery cannot be used in select statement,
whereas joins will allow to use join table columns in select statement
Performance is faster in JOINS compare to subquery
Complexity will be high in subquery
-Only 8 subquery is allowable in a single select statement
View vs Materialized view?
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
24/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
View only SQL query will be there and data will not be stored.
When running the view query, the select statement of view will be
executed. Extra memory is not required.
Materialized View it stores the data in raw table like normal tables.
Data refresh is required to update the data. Extra memory is required.
Explain about dierent types of joins?
Inner Join returns data if join condition matches between two
tables
Right Outer Join right side table will be considered as base table,
the datas are in right table will be returned. If join condition
matches it will return left table value else NULL value will be
returned
Left Outer Join left side table will be considered as base table, the
datas are in left table will be returned. If join condition matches it
will return right table value else NULL value will be returned
Full Outer Join combination of Right and Left outer join
Self Join any join type used for the same table
25/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
26/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
TESTING PROCESS:
Explain about testing life cycle
Explain about defect life cycle?
The dierence between Test Plan and Test Strategy?
Test Scenarios vs Test Cases
Regression Testing vs Retesting
Can you explain about Agile process?
Subscribe here
to get the new posts.
If you want to learn with an example project about all concepts and
end to end process,learn easily with a business project.
You can follow about ETL testing automation stu at,Automating ETL
test cases without any tool?
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
27/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
Shree Shakun
Heights
Goregaon East,
Mumbai
1, 2 BHK Flat
98.6 Lac - 1.94 Cr
Shree Shakun Realty Pvt. ...
Selenium Automation
Interview Questions
Records &
rank
Delete/Remove
Duplicate Records SQL
Author: balakrishnan
8 years of experience in ETL testing with strong knowledge of data warehouse
concepts and ETL concepts. Always passionate about learning new things from
fundamental, thinking and implementing innovative ideas with high job satisfaction.
View all posts by balakrishnan
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
28/29
10/12/2016
ETLDatawarehouseSQLtestingInterviewQuestionsandAnswers
WOW ETL Testing / Proudly powered by WordPress Copyright 2016 -All Rights Reserved /
http://wowetltesting.com/etldatawarehousetestinginterviewquestionsanswers/
29/29