Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Row vs Column Table Storage

Doc. No. G/L Amount Cost Center


1 E5000 50,000 CCPROD
2 S6000 25,000 CCSALE

3 E5000 10,000 CCPROD

4 S6010 15,000 CCRENT

Row Table Storage

1 E5000 50,000 CCPROD 2 S6000 25,000 CCSALE 3 E5000 10,000 CCPROD 4 S6010 15,000 CCRENT

Record 1 Record 2 Record 3 Record 4

Column Table Storage

1 2 3 4 E5000 S6000 E5000 S6010 50,000 25,000 10,000 15,000 CCPROD CCSALE CCPROD CCRENT

ID G/L Amount Cost Center


Row Operation – Transactional data search

Row Table Storage

1 E5000 50,000 CCPROD 2 S6000 25,000 CCSALE 3 E5000 10,000 CCPROD 4 S6010 15,000 CCRENT

1 Second
Column Table Storage

1 2 3 4 E5000 S6000 E5000 S6010 50,000 25,000 10,000 15,000 CCPROD CCSALE CCPROD CCRENT

4 Seconds
Column Operation – Analytical data search

Row Table Storage

1 E5000 50,000 CCPROD 2 S6000 25,000 CCSALE 3 E5000 10,000 CCPROD 4 S6010 15,000 CCRENT

4 Seconds
Column Table Storage

1 2 3 4 E5000 S6000 E5000 S6010 50,000 25,000 10,000 15,000 CCPROD CCSALE CCPROD CCRENT

2 Seconds
Advantages of Column-based table layout
Calculations are typically executed on single or few columns only
1

The table is searched based on values of a few columns


2

The table has a large number of records, and mostly columnar


3

operations are required (aggregate, scan, etc.)

The majority of the columns contain few distinct values compared


4

to the number of rows

You might also like