Thursday 12 November 2015

How can show the Data when data is located 3 different sheets in the single XL Workbook - Data Appending

Data Appending:
 
How can show the Data when data is located 3 different sheets in the single XL Workbook
Procedure:

Below are the XL sheets, where having data for 3 Countries in 3 Sheets.
23.png  24.png 25.png
1) All 3 Sheets are located in single XL Workbook.
2) Connect XL workbook (Sheet 1) to Tableau.
3) Then Extract the Data.
26.png        27.png
4) Connect to the Same XL workbook Sheet2.
29.png  30.png
5) Define the Relationship Between DB1 & DB2. Then Right click first DB Extract, click on "Append data from data source". Then refresh Extract
31.png     32.png
33.png
34.png36.png
6) Now we are having data fro 3 Countries (Which are located in 3 XL sheets in 1 Workbook.)

37.png
 
=========================
 

Data Appending: Record Level Merging
(Data Appending's Principle: Metadata should be same in all Databases & Sequence of Fields)
 
DB1
CNT State Sales
A A1 100
A A2 200
A A3 300

DB2
CNT State Sales
B B1 100
B B2 200
B B3 300

After Implement the Data Appending:
CNT State Sales
A A1 100
A A2 200
A A3 300
B B1 100
B B2 200
B B3 300
 
==============================
Data Appending is not Possible since Sequence of the Columns are not same in 2 Databases.

DB2
CNT State Sales
B B1 100
B B2 200
B B3 300

DB1
State Sales CNT
A1 100 A
A2 200 A
A3 300 A
==============================
Data Appending is not Possible since  Column names are not same in 2 Databases.

DB2
CNT State Sales
B B1 100
B B2 200
B B3 300


DB1
CNT             States         Sales
A A1 1000
A A2 2000
A A3 3000
 
==============================
Data Appending is not Possible since  Metadata is not same in 2 Databases.

DB1
CNT(Char 20) State(Char 20) Sales(Integer 12)
B B1 100
B B2 200
B B3 300

DB2
CNT(VarChar 20) States(Char 20) Sales(Integer 12)
A A1 1000
A A2 2000
A A3 3000

==============================
Data Appending is POSSIBLE since  Metadata, Sequence of the Fields are same in 2 Databases.

CNT(VarChar 20) State(Char 20) Sales(Integer 12)
B B1 100
B B2 200
B B3 300


CNT(VarChar 20) States(Char 20) Sales(Integer 12)
A A1 1000
A A2 2000
A A3 3000


After Implement the Data Appending:
CNT State Sales
A                  A1                100
A                  A2                 200
A A3 300
B B1 100
B B2 200
B B3 300

Data Appending Principle: Metadata, Sequence of the Columns should be same.
Meta Data: Column Name, Data Type, Size)

No comments:

Post a Comment