

{"id":38598,"date":"2018-11-18T10:00:18","date_gmt":"2018-11-18T04:30:18","guid":{"rendered":"https:\/\/data-flair.training\/blogs\/?p=38598"},"modified":"2021-12-07T11:20:12","modified_gmt":"2021-12-07T05:50:12","slug":"best-practice-for-data-modeling-in-qlikview","status":"publish","type":"post","link":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/","title":{"rendered":"Best Practice for Data Modeling in QlikView &#8211; 11 Unique Practices"},"content":{"rendered":"<p>The last session ends on <strong>QlikView Data Types<\/strong>. Here, we will talk about the importance of Data Modeling in QlikView.<\/p>\n<p>Moreover, we will learn the Best Practice for Data Modeling in QlikView with their examples.<\/p>\n<p>So, let&#8217;s start the tutorial of &#8220;Best Practice for Data Modeling in QlikView&#8221;.<\/p>\n<div id=\"attachment_38617\" style=\"width: 1210px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38617\" class=\"size-full wp-image-38617\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg\" alt=\"Best Practice for Data Modeling in QlikView - 11 Unique Practices\" width=\"1200\" height=\"628\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg 1200w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01-150x79.jpg 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01-300x157.jpg 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01-768x402.jpg 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01-1024x536.jpg 1024w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01-520x272.jpg 520w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/a><p id=\"caption-attachment-38617\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; 11 Unique Practices<\/p><\/div>\n<h3>Importance of QlikView Data Modeling<\/h3>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">A good data model ensures the\u00a0efficient working of your <strong>application in QlikView<\/strong>. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This means, the data will process faster, expressions will evaluate quickly and give correct results because all the data will properly arrange in cells so that the system can take a logical path to fetch and evaluate data values. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Also, by having a well-structured data model, the system\u2019s memory also consume economically avoiding occupying memory storage with access data.\u00a0<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Best practice for data modeling in QlikView is all about making your data well structured and logically feasible to optimize data processing and analysis in QlikView. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This can achieve by plotting out a design with specific operations (ETL) you need to perform on your intended data set in order to get your data in a perfect data model.<\/span><\/span><\/span><\/p>\n<h3 align=\"justify\">Best Practice for Data Modeling in QlikView<\/h3>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In QlikView, it prefers that you must design your data loading so that the data (in tables) takes the form of a <strong>star schema in QlikView<\/strong>. In a star schema, ideally, there is a fact table at the center containing the key fields that servers as a link to other tables. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The fact table also contains the numbers or measure values for calculation. Branching from this central fact table are the dimension tables which link to the central table by corresponding key fields. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In QlikView, the process of data loading can also explain by the process of ETL i.e. Extract, Transform and Load which encompasses all the operations and processes perform with data from start to end. Let us understand this process in some detail,<\/span><\/span><\/span><\/p>\n<ul>\n<li>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"><b>Extract<\/b><\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8211; In this step, as the name suggests, data extract from the data sources which are shown in the script by LOAD and SELECT statements. <\/span><\/span><\/span><\/p>\n<\/li>\n<li>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"><b>Transform<\/b><\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8211; In order to get the intended data structure, transforming the extracted data is quite necessary. Data transform by manipulating it using script functions and expressions. Transformation on a data table can be done using the Transformation wizard. Some common transformation operations apply to the data are; calculating new values, translating coded values, renaming fields, joining tables, aggregating values, pivoting and data validation.<\/span><\/span><\/span><\/p>\n<\/li>\n<li>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"><b>Load<\/b><\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8211; Loading is the last step in the process, where the final data, all process and alter is ready to load and use in QlikView. Data load when the script saves and execute. <\/span><\/span><\/span><\/p>\n<\/li>\n<\/ul>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Although, ELT is the conceptual approach to optimize data modeling, there are several actual best practice for data modelling in QlikView.<\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">i. Use QVD files for Incremental Load<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">As we know, an incremental load is just the new data or the updated data that is to add in an already existing data file. For better and faster loading of incremental load, <strong>QVD files<\/strong> recommend.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> The old data must be in the QVD files because they can retrieve at a much faster rate than the traditional Qvw files.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> So, during loading, the incremental data, the new data bunch load from the data source\/database (a slow process) and the old data fetch from the Qvd files (comparatively faster).<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> Then both these data (old and new) load into a new Qvd file and the file is saved. This process is repeated every time incremental data is to load. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38622\" style=\"width: 453px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd1.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38622\" class=\"size-full wp-image-38622\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd1.png\" alt=\"Best Practice for Data Modeling in QlikView\" width=\"443\" height=\"418\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd1.png 443w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd1-150x142.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd1-300x283.png 300w\" sizes=\"auto, (max-width: 443px) 100vw, 443px\" \/><\/a><p id=\"caption-attachment-38622\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; QVD Files<\/p><\/div>\n<h4 align=\"justify\">ii. Combining Tables with Join and Keep<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">To combine two <strong>tables<\/strong> which may or may not have fields or field values in common, <strong>Join<\/strong> and Keep prefixes are used in QlikView. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Although both the functions are used to combine or merge two or more tables, there is a difference between the two. When Join is used prefixing the Load or Select statements, it combines two tables and makes them one table. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The overriding values which in the same fields are taken only once and a single table is made having the unrepeated values of data. This newly created table is stored as a single internal table in QlikView\u2019s memory.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">On the other hand, if the user does not want to merge two tables and make it permanently one table containing all the data of two tables (which makes it quite bulky and slow to process), he can opt for Keep option. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The Keep option reduces the repeating or identical data from two tables and links them only from the intersection part, i.e. from the fields or records that truly match in both tables.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> Keep only establishes a link between the table and associates them and stores two separate tables instead of combining them and storing them as one table.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">By doing so, the table does not get too big in size, the matching data gets associated, memory is saved, processing gets faster and the associated tables can be used individually as well.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> As we know there three to four types of joins and keeps i.e. inner, outer (only join), left and right which gives different results upon using them join and keep. <\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">iii. Use Mapping as an Alternative to Joining<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">As we have discussed the issue of the size of the tables created by join in the previous section. Mapping is a good alternative to be used instead of Join. Join creates large in size tables and processing them slow down the tool.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> Instead, the Mapping function works much efficiently. Using Mapping keyword, you can map fields from one table into another. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Suppose we have two tables, named \u2018Customers\u2019 and \u2018Orders\u2019. The tables are shown below.<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38623\" style=\"width: 918px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38623\" class=\"wp-image-38623 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2.png\" alt=\"Best Practice for Data Modeling in QlikView\" width=\"908\" height=\"219\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2.png 908w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2-150x36.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2-300x72.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2-768x185.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd2-520x125.png 520w\" sizes=\"auto, (max-width: 908px) 100vw, 908px\" \/><\/a><p id=\"caption-attachment-38623\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Use Mapping as an Alternative to Joining<\/p><\/div>\n<div id=\"attachment_38624\" style=\"width: 879px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38624\" class=\"size-full wp-image-38624\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3.png\" alt=\"Best Practice for Data Modeling in QlikView - Use Mapping as an Alternative to Joining\" width=\"869\" height=\"217\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3.png 869w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3-150x37.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3-300x75.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3-768x192.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd3-520x130.png 520w\" sizes=\"auto, (max-width: 869px) 100vw, 869px\" \/><\/a><p id=\"caption-attachment-38624\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Use Mapping as an Alternative to Joining<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Now, what we want to do is map the Country field in the Orders table through the common field CustomerID. We want to do this because we also want country information corresponding to each customer\u2019s ID.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">For this, we will create a mapping table internally using the following script commands,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">First, we will create a mapping table named MapCustomerIDtoCountry.<\/span><\/span><\/span><\/p>\n<p lang=\"en-US\" align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">MapCustomerIDtoCountry:<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Mapping LOAD CustomerID, Country From Customers ;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The table created using will this will logically look like this,<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38625\" style=\"width: 816px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38625\" class=\"size-full wp-image-38625\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4.png\" alt=\"Best Practice for Data Modeling in QlikView - Use Mapping as an Alternative to Joining\" width=\"806\" height=\"216\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4.png 806w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4-150x40.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4-300x80.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4-768x206.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd4-520x139.png 520w\" sizes=\"auto, (max-width: 806px) 100vw, 806px\" \/><\/a><p id=\"caption-attachment-38625\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Use Mapping as an Alternative to Joining<\/p><\/div>\n<p lang=\"en-US\" align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Next, we will apply this mapping in the Orders table. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Orders:<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">S *,<\/span><\/span><\/p>\n<p><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">ApplyMap(&#8216;MapCustomerIDtoCountry&#8217;,CustomerID, null()) as Country<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">From Orders ;<\/span><\/span><\/p>\n<p lang=\"en-US\" align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This statement will apply the mapped table into the Orders table and countries will be shown for each customer ID. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38626\" style=\"width: 1021px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38626\" class=\"size-full wp-image-38626\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5.png\" alt=\"Best Practice for Data Modeling in QlikView - Use Mapping as an Alternative to Joining\" width=\"1011\" height=\"219\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5.png 1011w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5-150x32.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5-300x65.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5-768x166.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd5-520x113.png 520w\" sizes=\"auto, (max-width: 1011px) 100vw, 1011px\" \/><\/a><p id=\"caption-attachment-38626\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Use Mapping as an Alternative to Joining<\/p><\/div>\n<h4 align=\"justify\">iv. Working with Cross Tables<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Working with cross tables also optimizes the data model. Cross table is a like cross section of two orthogonal headers between which a matrix of data is filled. Let\u2019s take an example of the table below.<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38627\" style=\"width: 958px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38627\" class=\"wp-image-38627 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6.png\" alt=\"Best Practice for Data Modeling in QlikView - Working with Cross Tables\" width=\"948\" height=\"259\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6.png 948w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6-150x41.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6-300x82.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6-768x210.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd6-520x142.png 520w\" sizes=\"auto, (max-width: 948px) 100vw, 948px\" \/><\/a><p id=\"caption-attachment-38627\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Working with Cross Tables<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In this table there is one field for Year and then the separate field for each month. This table structure is not good and will create issues in the data model.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> To improve and resolve this issue, we have to create one field which contains all the months. This will be done by Crosstable prefix used before Load and Select statements.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><strong>Also, Refer QlikView Circular Reference and Loosely Coupled Tables<\/strong><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">crosstable (Month, Sales) LOAD * from ex1.xlsx<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This statement will create a cross table looking like this,<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38628\" style=\"width: 172px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd7.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38628\" class=\"size-full wp-image-38628\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd7.png\" alt=\"Best Practice for Data Modeling in QlikView - Working with Cross Tables\" width=\"162\" height=\"272\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd7.png 162w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd7-89x150.png 89w\" sizes=\"auto, (max-width: 162px) 100vw, 162px\" \/><\/a><p id=\"caption-attachment-38628\" class=\"wp-caption-text\">Working with Cross Tables<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This table has repeating year values for each month but a well-defined field called Month, structuring the data properly. <\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">v. Generic Databases<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">If the tables containing data follows a complex logic where one filed name has many records associated with it, then the best way is to create a Generic Database table.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> In a generic database table, there is a column containing field names as field values and then other columns which contain the field values. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Let us suppose a scenario where we have two objects Ball and Box and there are certain attributes like color, diameter, height etc. given for these objects.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> For such a data table, if we create list boxes for each field i.e. Object, Attribute and Value, it will look something like this.<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38629\" style=\"width: 618px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38629\" class=\"wp-image-38629 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8.png\" alt=\"Best Practice for Data Modeling in QlikView - Generic Databases\" width=\"608\" height=\"176\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8.png 608w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8-150x43.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8-300x87.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd8-520x151.png 520w\" sizes=\"auto, (max-width: 608px) 100vw, 608px\" \/><\/a><p id=\"caption-attachment-38629\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Generic Databases<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This shows that there are two objects Ball and Box for which there are some attributes and values given. But looking at these list boxes, can we tell what are the attributes and values for box and what are them for ball? No, right?<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">So, to give this messy chunk of data, a proper logic and structure, generic database tables are created.\u00a0<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38630\" style=\"width: 855px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38630\" class=\"size-full wp-image-38630\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9.png\" alt=\"Best Practice for Data Modeling in QlikView - Generic Databases\" width=\"845\" height=\"382\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9.png 845w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9-150x68.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9-300x136.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9-768x347.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd9-520x235.png 520w\" sizes=\"auto, (max-width: 845px) 100vw, 845px\" \/><\/a><p id=\"caption-attachment-38630\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Generic Databases<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Now, when we create list boxes from this generic table, with the statement,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Generic SELECT* from GenericTable;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The list boxes will display information in a well-structured manner than before. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38631\" style=\"width: 809px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38631\" class=\"size-full wp-image-38631\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10.png\" alt=\"Best Practice for Data Modeling in QlikView - Generic Databases\" width=\"799\" height=\"146\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10.png 799w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10-150x27.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10-300x55.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10-768x140.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd10-520x95.png 520w\" sizes=\"auto, (max-width: 799px) 100vw, 799px\" \/><\/a><p id=\"caption-attachment-38631\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Generic Databases<\/p><\/div>\n<h4 align=\"justify\">vi. Matching Intervals to Discrete Data<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">We are familiar with the <strong>Intervalmatch() function<\/strong> which is used to match or link discrete numeric or time interval values with other such values (from different tables). <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This operation on data can also be done carefully, keeping some points in mind to maintain a good data model.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Some things to keep in mind before using Intervalmatch() function is, that the discrete values must be read into QlikView before Intervalmatch() function calls them.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> Another thing is that the table to which the discrete data points will be matched or linked should at least have two fields (typically start and end fields) so that the interval is properly closed by an end time or terminating point. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">If the intervals overlap in the tables, they are linked with all corresponding or matching values. <\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">vii. Creating a Date Interval from a Single Date<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Sometimes, it so happens that instead of a beginning and end of an interval, only a single date is given. Like in the data set given below. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38632\" style=\"width: 296px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd11.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38632\" class=\"size-full wp-image-38632\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd11.png\" alt=\"Best Practice for Data Modeling in QlikView - Generic Databases\" width=\"286\" height=\"179\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd11.png 286w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd11-150x94.png 150w\" sizes=\"auto, (max-width: 286px) 100vw, 286px\" \/><\/a><p id=\"caption-attachment-38632\" class=\"wp-caption-text\">Date Interval from a Single Date<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">You can create a FromDate and ToDate intervals from the script commands given below,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Let vBeginTime = Num(&#8216;1\/1\/2013&#8217;);<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Let vEndTime = Num(&#8216;1\/3\/2013&#8217;);<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Let vEpsilon = Pow(2,-27);<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Tmp_Rates:<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">LOAD Currency, Rate,<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> Date(If(IsNum([Change Date]), [Change Date], $(#vBeginTime))) as FromDate<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">From &#8216;C:\\MyFiles\\Rates.xlsx&#8217; <\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">(ooxml, embedded labels, table is Sheet1);<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Rates:<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">LOAD Currency, Rate, FromDate,<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> Date(If( Currency=Peek(Currency),<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> Peek(FromDate) &#8211; $(#vEpsilon),<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> $(#vEndTime)<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> )) as ToDate<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> Resident Tmp_Rates<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\"> Order By Currency, FromDate Desc;<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Drop Table Tmp_Rates;<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This will create a table with intervals. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38633\" style=\"width: 502px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd12.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38633\" class=\"size-full wp-image-38633\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd12.png\" alt=\"Date Interval from a Single Date\" width=\"492\" height=\"171\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd12.png 492w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd12-150x52.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd12-300x104.png 300w\" sizes=\"auto, (max-width: 492px) 100vw, 492px\" \/><\/a><p id=\"caption-attachment-38633\" class=\"wp-caption-text\">Date Interval from a Single Date<\/p><\/div>\n<h4 align=\"justify\">viii. Hierarchies<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">A well-balanced n-level of a hierarchy is very important to have for a good data structure and in turn, a good data model. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">There are different modes of representation for hierarchies i.e, Adjacent nodes table, Expanded nodes table and ancestors or bridge node table. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The adjacent node table is the most basic way of tabular representation of a field hierarchy.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> It shows the child and the parent node and one field corresponding to that node.\u00a0<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38634\" style=\"width: 382px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd13.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38634\" class=\"wp-image-38634 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd13.png\" alt=\"Best Practice for Data Modeling in QlikView - Hierarchies\" width=\"372\" height=\"134\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd13.png 372w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd13-150x54.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd13-300x108.png 300w\" sizes=\"auto, (max-width: 372px) 100vw, 372px\" \/><\/a><p id=\"caption-attachment-38634\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Hierarchies<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">While adjacent node tables are good for management purposes but not that informative for doing selections and analysis.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> For this, expanded node tables are used which provides the sub-fields or sub-levels of the main fields of the hierarchy. It expands or spreads the hierarchy to its length.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> An expanded table can be created using the script command below,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Hierarchy (NodeID, ParentNodeID, Title, &#8216;Manager&#8217;) LOAD<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">NodeID,<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">ParentNodeID,<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">Title<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span lang=\"en-US\">FROM &#8216;hierarchy.txt&#8217; (txt, codepage is 1252, embedded labels, delimiter is &#8216;,&#8217;, msq);<\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Here, we have converted the adjacent table into expanded table which looks like this,<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38637\" style=\"width: 887px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38637\" class=\"size-full wp-image-38637\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14.png\" alt=\"Best Practice for Data Modeling in QlikView - Hierarchies\" width=\"877\" height=\"122\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14.png 877w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14-150x21.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14-300x42.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14-768x107.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd14-520x72.png 520w\" sizes=\"auto, (max-width: 877px) 100vw, 877px\" \/><\/a><p id=\"caption-attachment-38637\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Hierarchies<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">However, making selections in expanded tables is also a tedious task and requires you to already know about the hierarchy of the data. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">To counter this issue, Ancestors node tables use. These tables represent hierarchies in further detail. They have separate records for each node giving details of parent and children nodes showing which node a specific node belongs to.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">To convert\u00a0expande\u00a0or adjacent nodes table to an ancestors table, use the keyword <\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"><b>Hierarchybelongsto<\/b><\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> in the load script. <\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">ix. Semantic Links<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The Semantic Links are the associations or the links that are present between the values within a field or between fields. A semantic table creates which has the details or logic of these associations between data values. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In a semantic table, there are generally four columns, the first column has the values which link or associate to other values, the second column shows the relation between the two, the third column contains the values with which the values in the first column associate.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> And lastly, the fourth column (if present) will show the inverse of the relation shown in the second column. There are certain things which must be kept in mind while making a semantic table i.e. the table must have three or four columns, not less. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The relation\/association between the values must be either in the values present within a field or between the values of different fields. A combination of these two types not allow. There must be a <\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"><b>Semantic<\/b><\/span><\/span><\/span><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> qualifier must use before the Load or Select statements.<\/span><\/span><\/span><\/p>\n<h5 align=\"justify\">a. Semantic links Example<\/h5>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Let us understand to make selections using the semantic table with an example. We have taken sample data from QlikView\u2019s example directory. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The name of the table is Presidents, which contains details about all the presidents, from the first to present, that has served in USA. There are three columns in this table, which are, Sequence, Name and Party. <\/span><\/span><\/span><\/p>\n<div id=\"attachment_38638\" style=\"width: 429px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd15.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38638\" class=\"size-full wp-image-38638\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd15.png\" alt=\"Best Practice for Data Modeling in QlikView -\" width=\"419\" height=\"925\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd15.png 419w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd15-68x150.png 68w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd15-136x300.png 136w\" sizes=\"auto, (max-width: 419px) 100vw, 419px\" \/><\/a><p id=\"caption-attachment-38638\" class=\"wp-caption-text\">Semantic links Example<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Now, we will make a semantic table such that the relation between the values (President\u2019s names) will be of successors and predecessor. The script for creating such a table would be,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Directory presidents;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Load * from presdnts.csv (ansi, txt, delimiter<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">is &#8216;,&#8217;, embedded labels);<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Semantic Load<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No -1 as No,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8216;Successor&#8217; as Relation,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8216;Predecessor&#8217; as Relation<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">from presdnts.csv (ansi, txt, delimiter is &#8216;,&#8217;,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">embedded labels) where No &gt; 1;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This will generate a sematic table with four columns; No (values link to other values), Relation (Successor), No (values with which the previous values link to), Relation(Predecessor).<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38639\" style=\"width: 337px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd16.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38639\" class=\"size-full wp-image-38639\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd16.png\" alt=\"Best Practice for Data Modeling in QlikView\" width=\"327\" height=\"260\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd16.png 327w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd16-150x119.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd16-300x239.png 300w\" sizes=\"auto, (max-width: 327px) 100vw, 327px\" \/><\/a><p id=\"caption-attachment-38639\" class=\"wp-caption-text\">Semantic links<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Now, we will load this semantic table into our main script handling data and execute it to be able to create sheet objects (tables, lists, charts etc.)<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Load<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No as DuplicateOfNo,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">FirstName &amp; &#8216; &#8216; &amp; LastName as Name,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">*f<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">rom presdnts.csv;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Semantic Load<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No -1 as No,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">FirstName &amp; &#8216; &#8216; &amp; LastName as Successor,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No as DuplicateOfNo,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8216;Dummy1&#8217;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">from presdnts.csv where No &gt; 1;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Semantic Load<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No +1 as No,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">FirstName &amp;&#8217; &#8216; &amp; LastName as Predecessor,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">No as DuplicateOfNo,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">&#8216;Dummy2&#8217;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">from presdnts.csv;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">The table created will look like this,<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38640\" style=\"width: 1018px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38640\" class=\"wp-image-38640 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17.png\" alt=\"Best Practice for Data Modeling in QlikView\" width=\"1008\" height=\"342\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17.png 1008w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17-150x51.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17-300x102.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17-768x261.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd17-520x176.png 520w\" sizes=\"auto, (max-width: 1008px) 100vw, 1008px\" \/><\/a><p id=\"caption-attachment-38640\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Semantic Load<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">You can make selections in the center table and the corresponding successors and predecessors will show in the right and left tables using the semantic links define in the semantic table.<\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">x. Linking Information to Field Values<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In QlikView, it is all about how well use the data and information available to you and display it in such a way that the user could analyze it properly. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Adding to this purpose is the feature of linking information to field values in the table. You can add information like a text information, an image, URL, external application files etc. to the field values of a table. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">There is an information table generate through script commands that keep the details of all the information that link to specific field values. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">A sample statement to create an information table is,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Info Load Country, I from Flagsoecd.csv (ansi, txt, delimiter is &#8216;,&#8217;, embedded labels);<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This will create an information table given below,<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38641\" style=\"width: 531px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38641\" class=\"wp-image-38641 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18.png\" alt=\"Best Practice for Data Modeling in QlikView - Linking Information to Field Values\" width=\"521\" height=\"363\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18.png 521w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18-150x105.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18-300x209.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd18-520x362.png 520w\" sizes=\"auto, (max-width: 521px) 100vw, 521px\" \/><\/a><p id=\"caption-attachment-38641\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Linking Information to Field Values<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">As you can see, an information table has two columns in general, the first column is a field name containing a list of all the field values to which different kinds of information is to link.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> The second column has the names and the information or references to information in it. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Upon script execution, the fields values in the table that link to some information will get an icon at the corner of the table cells containing them. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Clicking upon those icons you will get to access the information. The information link could be anything, like a text, an image, a sound clip, a link to a video, an executable file, a file destination, URL etc. <\/span><\/span><\/span><\/p>\n<h4 align=\"justify\">xi. Data Cleansing<\/h4>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In our effort to optimize our data model in QlikView, avoiding storage access data must avoid. That is why data cleansing practice. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Let us consider a scenario, where we have two tables; Country A and Country B each of them has U.S.A. written in different ways like US, USA, Unites States, U.S., America.\u00a0<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38642\" style=\"width: 891px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38642\" class=\"size-full wp-image-38642\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19.png\" alt=\"Best Practice for Data Modeling in QlikView - Data Cleansing\" width=\"881\" height=\"287\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19.png 881w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19-150x49.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19-300x98.png 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19-768x250.png 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd19-520x169.png 520w\" sizes=\"auto, (max-width: 881px) 100vw, 881px\" \/><\/a><p id=\"caption-attachment-38642\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Data Cleansing<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">This creates redundant data as separate records in memory will create for each of these names because the system will interpret them as different values when in reality, it is the same country. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">To cleanse such an access data create Mapping use. What happens by using mapping is that the original table store and stays in the memory while only a mapped version of it use during execution.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\"> When the script execution terminates, this temporary table drop.<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">In the case we just discuss, we will create a mapping table and link it with our Country A and Country B tables. The script use for doing so is,<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">CountryMap:<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Mapping Load x,y from MappingTable.txt<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">(ansi, txt, delimiter is &#8216;,&#8217;, embedded<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">labels);<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Map Country using CountryMap;<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Load Country,City from CountryA.txt<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">(ansi, txt, delimiter is &#8216;,&#8217;, embedded labels);<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Load Country, City from CountryB.txt<\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Courier New, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">(ansi, txt, delimiter is &#8216;,&#8217;, embedded labels);<\/span><\/span><\/span><\/p>\n<div id=\"attachment_38643\" style=\"width: 500px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd20.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38643\" class=\"size-full wp-image-38643\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd20.png\" alt=\"Best Practice for Data Modeling in QlikView - Data Cleansing\" width=\"490\" height=\"316\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd20.png 490w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd20-150x97.png 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/bpd20-300x193.png 300w\" sizes=\"auto, (max-width: 490px) 100vw, 490px\" \/><\/a><p id=\"caption-attachment-38643\" class=\"wp-caption-text\">Best Practice for Data Modeling in QlikView &#8211; Data Cleansing<\/p><\/div>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">Now regardless of how the name of the United States of America is written, it will interpret as the U.S.A. only.<\/span><\/span><\/span><\/p>\n<p align=\"justify\">So, this was all about\u00a0Best Practice for Data Modeling in QlikView. Hope you like our explanation.<\/p>\n<h3 align=\"justify\">Conclusion<\/h3>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">These were all the best practice for Data Modeling in QlikView that you must keep in mind while preparing your script, as this will reflect in your data model. <\/span><\/span><\/span><\/p>\n<p align=\"justify\"><span style=\"font-family: Arial, serif\"><span style=\"font-size: medium\"><span lang=\"en-US\">A good script means a good data model and better your application performs. Read and understand these practices thoroughly and try to apply them to your data set. Still, have a confusion, feel free to ask in the comment box.<\/span><\/span><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>The last session ends on QlikView Data Types. Here, we will talk about the importance of Data Modeling in QlikView. Moreover, we will learn the Best Practice for Data Modeling in QlikView with their&#46;&#46;&#46;<\/p>\n","protected":false},"author":6,"featured_media":38617,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[47],"tags":[17301,17294,17300,17297,17295,17298,17302,17296,16870,17292,17291,17299,17293],"class_list":["post-38598","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-qlikview","tag-best-practices-for-data-modeling","tag-cross-tables","tag-data-cleansing","tag-date-interval","tag-generic-databases","tag-hierarchies","tag-importance-of-qlikview-data-modeling","tag-matching-intervals","tag-qlikview-incremental-load","tag-qlikview-join-and-keep","tag-qvd-files","tag-semantic-links","tag-use-mapping"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Best Practice for Data Modeling in QlikView - 11 Unique Practices - DataFlair<\/title>\n<meta name=\"description\" content=\"11 Best Practice for Data Modeling in QlikView-Importance of QlikView Data Model, QVD Files, Date Interval, Hierarchies, Semantic Links, Data Cleansing\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Best Practice for Data Modeling in QlikView - 11 Unique Practices - DataFlair\" \/>\n<meta property=\"og:description\" content=\"11 Best Practice for Data Modeling in QlikView-Importance of QlikView Data Model, QVD Files, Date Interval, Hierarchies, Semantic Links, Data Cleansing\" \/>\n<meta property=\"og:url\" content=\"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/\" \/>\n<meta property=\"og:site_name\" content=\"DataFlair\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/DataFlairWS\/\" \/>\n<meta property=\"article:published_time\" content=\"2018-11-18T04:30:18+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-12-07T05:50:12+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"628\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"DataFlair Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:site\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"DataFlair Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"19 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Best Practice for Data Modeling in QlikView - 11 Unique Practices - DataFlair","description":"11 Best Practice for Data Modeling in QlikView-Importance of QlikView Data Model, QVD Files, Date Interval, Hierarchies, Semantic Links, Data Cleansing","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/","og_locale":"en_US","og_type":"article","og_title":"Best Practice for Data Modeling in QlikView - 11 Unique Practices - DataFlair","og_description":"11 Best Practice for Data Modeling in QlikView-Importance of QlikView Data Model, QVD Files, Date Interval, Hierarchies, Semantic Links, Data Cleansing","og_url":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/","og_site_name":"DataFlair","article_publisher":"https:\/\/www.facebook.com\/DataFlairWS\/","article_published_time":"2018-11-18T04:30:18+00:00","article_modified_time":"2021-12-07T05:50:12+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg","type":"image\/jpeg"}],"author":"DataFlair Team","twitter_card":"summary_large_image","twitter_creator":"@DataFlairWS","twitter_site":"@DataFlairWS","twitter_misc":{"Written by":"DataFlair Team","Est. reading time":"19 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#article","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/"},"author":{"name":"DataFlair Team","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/2c58ecb4f73a39f0ef993f1ddfcd7b89"},"headline":"Best Practice for Data Modeling in QlikView &#8211; 11 Unique Practices","datePublished":"2018-11-18T04:30:18+00:00","dateModified":"2021-12-07T05:50:12+00:00","mainEntityOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/"},"wordCount":3299,"commentCount":0,"publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg","keywords":["Best Practices for Data Modeling","Cross Tables","Data Cleansing","Date Interval","Generic Databases","Hierarchies","Importance of QlikView Data Modeling","Matching Intervals","QlikView Incremental Load","QlikView Join and Keep","QVD files","Semantic Links","Use Mapping"],"articleSection":["QlikView Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/","url":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/","name":"Best Practice for Data Modeling in QlikView - 11 Unique Practices - DataFlair","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/#website"},"primaryImageOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#primaryimage"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg","datePublished":"2018-11-18T04:30:18+00:00","dateModified":"2021-12-07T05:50:12+00:00","description":"11 Best Practice for Data Modeling in QlikView-Importance of QlikView Data Model, QVD Files, Date Interval, Hierarchies, Semantic Links, Data Cleansing","breadcrumb":{"@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#primaryimage","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/10\/Best-Practices-for-Data-Modeling-in-QlikView-01.jpg","width":1200,"height":628,"caption":"Best Practice for Data Modeling in QlikView - 11 Unique Practices"},{"@type":"BreadcrumbList","@id":"https:\/\/data-flair.training\/blogs\/best-practice-for-data-modeling-in-qlikview\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog Home","item":"https:\/\/data-flair.training\/blogs\/"},{"@type":"ListItem","position":2,"name":"QlikView Tutorials","item":"https:\/\/data-flair.training\/blogs\/category\/qlikview\/"},{"@type":"ListItem","position":3,"name":"Best Practice for Data Modeling in QlikView &#8211; 11 Unique Practices"}]},{"@type":"WebSite","@id":"https:\/\/data-flair.training\/blogs\/#website","url":"https:\/\/data-flair.training\/blogs\/","name":"DataFlair","description":"Learn Today. Lead Tomorrow.","publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/data-flair.training\/blogs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/data-flair.training\/blogs\/#organization","name":"DataFlair","url":"https:\/\/data-flair.training\/blogs\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","width":106,"height":48,"caption":"DataFlair"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/DataFlairWS\/","https:\/\/x.com\/DataFlairWS","https:\/\/www.linkedin.com\/company\/dataflair-web-services-pvt-ltd\/","https:\/\/www.youtube.com\/user\/DataFlairWS"]},{"@type":"Person","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/2c58ecb4f73a39f0ef993f1ddfcd7b89","name":"DataFlair Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/1ce4a0e3e542444fc73bbebf83e89e8b73e2d95ccb1fcee64da9945f078b97c5?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/1ce4a0e3e542444fc73bbebf83e89e8b73e2d95ccb1fcee64da9945f078b97c5?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1ce4a0e3e542444fc73bbebf83e89e8b73e2d95ccb1fcee64da9945f078b97c5?s=96&d=mm&r=g","caption":"DataFlair Team"},"description":"The DataFlair Team provides industry-driven content on programming, Java, Python, C++, DSA, AI, ML, data Science, Android, Flutter, MERN, Web Development, and technology. Our expert educators focus on delivering value-packed, easy-to-follow resources for tech enthusiasts and professionals.","url":"https:\/\/data-flair.training\/blogs\/author\/dfteam2\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/38598","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/comments?post=38598"}],"version-history":[{"count":10,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/38598\/revisions"}],"predecessor-version":[{"id":104947,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/38598\/revisions\/104947"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media\/38617"}],"wp:attachment":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media?parent=38598"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/categories?post=38598"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/tags?post=38598"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}