Denormalizing for performance
Good transactional database design suggests that data tables should be normalized, at least to third normal form. But this is not necessarily the most efficient for QlikView.
In a QlikView data model, the more association links between two fields, the longer it will take to calculate the result of one versus the other.
By that logic, it might make sense to consider that a single table model is the most efficient in QlikView. But that is not necessarily the case either.
Getting ready
Generate QVDs
created in the Reducing the number of distinct values recipe.
How to do it…
These steps demonstrate how to denormalize for performance:
Create a new
QVW
file in the same folder asQVDs
and load the following script:Sales: LOAD //SalesID, Hour(TransactionDate) As TransHour, DateID, ProductID, CustomerID, Discount, Quantity, SalePrice, Sales FROM [Sales.qvd] (qvd); Calendar: LOAD DateID, Date, Year, Month, ...