{"id":4866,"date":"2015-06-12T07:47:26","date_gmt":"2015-06-12T05:47:26","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/"},"modified":"2015-06-12T07:47:26","modified_gmt":"2015-06-12T05:47:26","slug":"sap-hana-sql-scripting-optimization-the-ce-functions","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/","title":{"rendered":"SAP HANA SQL scripting optimization: the CE Functions"},"content":{"rendered":"<p><img decoding=\"async\" class=\"blog-image aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\" alt=\"\" \/><br \/>\nIn SAP HANA, you have two possibilities to create the Calculated Views:<\/p>\n<ul>\n<li>Using the graphical method<\/li>\n<li>Using the scripting method with CE functions<\/li>\n<\/ul>\n<p>In this blog, I will demonstrate that CE Functions can improve performances from a Calculated View.<\/p>\n<p>First, I will give you some general information regarding the CE Functions. After that, I will show you the two different ways to create a Calculated View. And at the end, I will compare their performances using a SQL select.<\/p>\n<p>If you want to have more information regarding the SAP HANA technology, don&#8217;t hesitate to assist at the next dbi services event:<br \/>\n<a title=\"Newsroom event\" href=\"https:\/\/www.dbi-services.com\/newsroom\/events\/\">https:\/\/www.dbi-services.com\/newsroom\/events\/<\/a><\/p>\n<h3>CE Functions<\/h3>\n<p>The CE Functions encapsulate data-transformation functionalities. They constitute an alternative to using SQL statements as their logic is directly implemented in the Sap HANA CALC engine. Direct use of the CALC engine allows implementers to influence the execution of a procedure or a query which, in some cases, is more efficient.<\/p>\n<p>In the table below, you can find the list of the CE Functions and their use cases:<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"1_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/1_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"1_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/1_SAP_HANA_CEF.png\" alt=\"1_SAP_HANA_CEF.PNG\" width=\"627\" height=\"439\" \/><\/a><\/p>\n<h4>How to create a Calculation View<\/h4>\n<p>As I say at the beginning, you have two methods to create a Calculation View in Sap HANA:<\/p>\n<ul>\n<li>Using the graphical method<\/li>\n<li>Using the Scripting method<\/li>\n<\/ul>\n<h4>Using the graphical Method<\/h4>\n<p>Right click on a package and select \u201cNew \/ Calculation View\u201d<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"2_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"2_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2_SAP_HANA_CEF.png\" alt=\"2_SAP_HANA_CEF.PNG\" width=\"400\" height=\"238\" \/><\/a><\/p>\n<p>Select the \u201cGraphical\u201d type<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"3_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/3_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"3_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/3_SAP_HANA_CEF.png\" alt=\"3_SAP_HANA_CEF.PNG\" width=\"400\" height=\"472\" \/><\/a><\/p>\n<p>Create your view following the steps below<\/p>\n<p>1. Select type of operation you want to perform<br \/>\n2. Select your sources<br \/>\n3. Join your sources<br \/>\n4. Select the object you want to use in your Calculation view<br \/>\n5. Join your \u201cAggregation operation\u201d to the \u201cAggregation\u201d box<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"4_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/4_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"4_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/4_SAP_HANA_CEF.png\" alt=\"4_SAP_HANA_CEF.PNG\" width=\"566\" height=\"294\" \/><\/a><\/p>\n<p>Create your Calculation View Layout<\/p>\n<p>1. Click on the \u201cAggregation\u201d box<br \/>\n2. Select the object you want to have in your layout<br \/>\n3. Check if the object are selected and add, if needed, calculated columns<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"5_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/5_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"5_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/5_SAP_HANA_CEF.png\" alt=\"5_SAP_HANA_CEF.PNG\" width=\"566\" height=\"139\" \/><\/a><\/p>\n<p>Check the objects<\/p>\n<p>1. Click on \u201cSemantics\u201d box<br \/>\n2. Select the type of the objects<br \/>\n3. Validate and activate the view<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"6_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/6_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"6_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/6_SAP_HANA_CEF.png\" alt=\"6_SAP_HANA_CEF.PNG\" width=\"567\" height=\"219\" \/><\/a><\/p>\n<h4>Using the \u201cSQL scripting\u201d Method<\/h4>\n<p>Right click on a package and select \u201cNew \/ Calculation View\u201d<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"7_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/7_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"7_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/7_SAP_HANA_CEF.png\" alt=\"7_SAP_HANA_CEF.PNG\" width=\"399\" height=\"237\" \/><\/a><\/p>\n<p>Select the \u201cSQL Script\u201d type<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"8_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/8_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"8_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/8_SAP_HANA_CEF.png\" alt=\"8_SAP_HANA_CEF.PNG\" width=\"400\" height=\"478\" \/><\/a><\/p>\n<p>Create your view following the steps below<\/p>\n<p>1. Click on the \u201cScript View\u201d box<br \/>\n2. Type our SQL script<br \/>\n3. Introduce the CE functions<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"9_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/9_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"9_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/9_SAP_HANA_CEF.png\" alt=\"9_SAP_HANA_CEF.PNG\" width=\"566\" height=\"440\" \/><\/a><\/p>\n<p>Check the objects<\/p>\n<p>1. Click on \u201cSemantics\u201d box<br \/>\n2. Select the type of the objects<br \/>\n3. Validate and activate the view<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"10_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/10_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"10_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/10_SAP_HANA_CEF.png\" alt=\"10_SAP_HANA_CEF.PNG\" width=\"566\" height=\"220\" \/><\/a><\/p>\n<h3>SQL Performance comparison<\/h3>\n<h4>Goal of the test<\/h4>\n<p>In this part, I will compare the SQL performance from two calculated views that have been built with the two different methods:<\/p>\n<ul>\n<li>\u201cGraphical\u201d method<\/li>\n<li>\u201cSQL scripting\u201d method<\/li>\n<\/ul>\n<h4>Description of the test<\/h4>\n<p>The same SELECT query will be send to the database and we will check the Server time response. The two SELECT will use a different calculated view as data source:<\/p>\n<ul>\n<li>CAL_AMOUNT (graphical method)<\/li>\n<li>CAL_AMOUNT_CE (SQL Scripting method)<\/li>\n<\/ul>\n<h4>Test with the \u201cGraphical\u201d calculated view<\/h4>\n<h4>SQL Query<\/h4>\n<p><a class=\"easyblog-thumb-preview\" title=\"11_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/11_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"11_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/11_SAP_HANA_CEF.png\" alt=\"11_SAP_HANA_CEF.PNG\" width=\"240\" height=\"316\" \/><\/a><\/p>\n<h4>Performance<\/h4>\n<p><a class=\"easyblog-thumb-preview\" title=\"12_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/12_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"12_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/12_SAP_HANA_CEF.png\" alt=\"12_SAP_HANA_CEF.PNG\" width=\"566\" height=\"40\" \/><\/a><\/p>\n<h3>Test with the \u201cSQL Scripting\u201d calculated view<\/h3>\n<h3>SQL Query<\/h3>\n<p><a class=\"easyblog-thumb-preview\" title=\"13_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/13_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"13_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/13_SAP_HANA_CEF.png\" alt=\"13_SAP_HANA_CEF.PNG\" width=\"260\" height=\"304\" \/><\/a><\/p>\n<h4>Performance<\/h4>\n<p><a class=\"easyblog-thumb-preview\" title=\"14_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/14_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"14_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/14_SAP_HANA_CEF.png\" alt=\"14_SAP_HANA_CEF.PNG\" width=\"560\" height=\"38\" \/><\/a><\/p>\n<h3>Performance decoding<\/h3>\n<p>Why the use of these CE functions boost the performances of your queries? The explanation is located in the query execution plan and especially in the use of the CALC engine from the SAP HANA database.<\/p>\n<p>When you send a \u201cnormal\u201d SQL query in the SAP HANA database, the CALC engine is not used. The SQL parser send the query directly to the \u201cDatabase optimizer\u201d to optimize the execution of the query (1).<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"15_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/15_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"15_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/15_SAP_HANA_CEF.png\" alt=\"15_SAP_HANA_CEF.PNG\" width=\"560\" height=\"335\" \/><\/a><\/p>\n<p>When your SELECT query uses a calclated view with CE functions, the CALC Engine optimizes the calculation model.<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"16_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/16_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"16_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/16_SAP_HANA_CEF.png\" alt=\"16_SAP_HANA_CEF.PNG\" width=\"560\" height=\"331\" \/><\/a><\/p>\n<p>In our case, when we analyze the \u201cnormal\u201d SQL query, the \u201ccalculation search\u201d task has been split in 3 different sub-queries that can\u2019t start at the same time.<\/p>\n<p>But with the optimized calculated view, we can remark that there is only 2 sub-queries.<\/p>\n<p><a class=\"easyblog-thumb-preview\" title=\"17_SAP_HANA_CEF.PNG\" href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/17_SAP_HANA_CEF.png\"><img loading=\"lazy\" decoding=\"async\" title=\"17_SAP_HANA_CEF.PNG\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/17_SAP_HANA_CEF.png\" alt=\"17_SAP_HANA_CEF.PNG\" width=\"561\" height=\"247\" \/><\/a><\/p>\n<h3>Conclusion<\/h3>\n<p>The use of CE functions in the creation of calculated views can significantly accelerate the execution of your SQL queries. The CALC engine from SAP HANA is optimize to use these functions.<\/p>\n<p>There\u2019s only one restriction using this kind of functions. The performance will dramatically reduce if you try to create a SQL query mixing \u201cnormal\u201d and \u201coptimized\u201d calculated views.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In SAP HANA, you have two possibilities to create the Calculated Views: Using the graphical method Using the scripting method with CE functions In this blog, I will demonstrate that CE Functions can improve performances from a Calculated View. First, I will give you some general information regarding the CE Functions. After that, I will [&hellip;]<\/p>\n","protected":false},"author":17,"featured_media":4832,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[368],"tags":[579,280,222,587,582],"type_dbi":[],"class_list":["post-4866","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-development-performance","tag-column-store","tag-database","tag-in-memory","tag-olap","tag-sap-hana"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>SAP HANA SQL scripting optimization: the CE Functions - dbi Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SAP HANA SQL scripting optimization: the CE Functions\" \/>\n<meta property=\"og:description\" content=\"In SAP HANA, you have two possibilities to create the Calculated Views: Using the graphical method Using the scripting method with CE functions In this blog, I will demonstrate that CE Functions can improve performances from a Calculated View. First, I will give you some general information regarding the CE Functions. After that, I will [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2015-06-12T05:47:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"157\" \/>\n\t<meta property=\"og:image:height\" content=\"56\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Alain Lacour\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alain Lacour\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\"},\"author\":{\"name\":\"Alain Lacour\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\"},\"headline\":\"SAP HANA SQL scripting optimization: the CE Functions\",\"datePublished\":\"2015-06-12T05:47:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\"},\"wordCount\":678,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\",\"keywords\":[\"Column Store\",\"database\",\"In-memory\",\"OLAP\",\"SAP HANA\"],\"articleSection\":[\"Development &amp; Performance\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\",\"name\":\"SAP HANA SQL scripting optimization: the CE Functions - dbi Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\",\"datePublished\":\"2015-06-12T05:47:26+00:00\",\"author\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\",\"contentUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg\",\"width\":157,\"height\":56},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/www.dbi-services.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SAP HANA SQL scripting optimization: the CE Functions\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\",\"name\":\"Alain Lacour\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"caption\":\"Alain Lacour\"},\"description\":\"Alain Lacour has more than 15 years of experience in application development with Oracle technologies. He is specialized in APEX, Java, and PL\/SQL development. His expertise also includes middleware technologies such as Oracle Weblogic and EMC Documentum. He also has a broad experience in business analysis and architecture solutions as well as in service and project management. Prior to dbi services, Alain Lacour was Senior Consultant at IMS Health in Basel. He also worked as a Software Engineer for M&amp;H Informatics in Basel. Alain Lacour holds a Master of Science in Industrial Computing from the University of Mulhouse (F). His branch-related experience mainly covers the pharma industry, with an in-depth knowledge of the drug development process as well as drug distribution.\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/author\/alain-lacour\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"SAP HANA SQL scripting optimization: the CE Functions - dbi Blog","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:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/","og_locale":"en_US","og_type":"article","og_title":"SAP HANA SQL scripting optimization: the CE Functions","og_description":"In SAP HANA, you have two possibilities to create the Calculated Views: Using the graphical method Using the scripting method with CE functions In this blog, I will demonstrate that CE Functions can improve performances from a Calculated View. First, I will give you some general information regarding the CE Functions. After that, I will [&hellip;]","og_url":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/","og_site_name":"dbi Blog","article_published_time":"2015-06-12T05:47:26+00:00","og_image":[{"width":157,"height":56,"url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg","type":"image\/jpeg"}],"author":"Alain Lacour","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alain Lacour","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/"},"author":{"name":"Alain Lacour","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0"},"headline":"SAP HANA SQL scripting optimization: the CE Functions","datePublished":"2015-06-12T05:47:26+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/"},"wordCount":678,"commentCount":0,"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg","keywords":["Column Store","database","In-memory","OLAP","SAP HANA"],"articleSection":["Development &amp; Performance"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/","url":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/","name":"SAP HANA SQL scripting optimization: the CE Functions - dbi Blog","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage"},"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg","datePublished":"2015-06-12T05:47:26+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0"},"breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#primaryimage","url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg","contentUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/2e1ax_default_entry_logo_sap_hana.jpg","width":157,"height":56},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/sap-hana-sql-scripting-optimization-the-ce-functions\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"SAP HANA SQL scripting optimization: the CE Functions"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0","name":"Alain Lacour","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","caption":"Alain Lacour"},"description":"Alain Lacour has more than 15 years of experience in application development with Oracle technologies. He is specialized in APEX, Java, and PL\/SQL development. His expertise also includes middleware technologies such as Oracle Weblogic and EMC Documentum. He also has a broad experience in business analysis and architecture solutions as well as in service and project management. Prior to dbi services, Alain Lacour was Senior Consultant at IMS Health in Basel. He also worked as a Software Engineer for M&amp;H Informatics in Basel. Alain Lacour holds a Master of Science in Industrial Computing from the University of Mulhouse (F). His branch-related experience mainly covers the pharma industry, with an in-depth knowledge of the drug development process as well as drug distribution.","url":"https:\/\/www.dbi-services.com\/blog\/author\/alain-lacour\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/4866","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/17"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=4866"}],"version-history":[{"count":0,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/4866\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media\/4832"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=4866"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=4866"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=4866"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=4866"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}