Using Functions, Formulas and Calculations in Web Intelligence Content

Total Page:16

File Type:pdf, Size:1020Kb

Using Functions, Formulas and Calculations in Web Intelligence Content SAP BusinessObjects Business Intelligence Suite Document Version: 4.2 Support Package 2 – 2016-03-07 Using functions, formulas and calculations in Web Intelligence Content 1 Document History: Web Intelligence Functions, Formulas and Calculations..................5 2 About this guide...............................................................6 3 Using standard and custom calculations.............................................7 3.1 Standard calculations............................................................ 7 3.2 Using formulas to build custom calculations............................................ 8 Using variables to simplify formulas................................................8 3.3 Working with functions........................................................... 8 Including functions in cells...................................................... 9 Function syntax..............................................................9 Examples of functions..........................................................9 Function and formula operators..................................................14 4 Understanding calculation contexts............................................... 16 4.1 The input context...............................................................16 4.2 The output context..............................................................17 4.3 Default calculation contexts.......................................................19 Default contexts in a vertical table................................................20 Default contexts in a horizontal table.............................................. 21 Default contexts in a crosstab table............................................... 21 Default contexts in a section....................................................22 Default contexts in a break..................................................... 23 4.4 Modifying the default calculation context with extended syntax..............................24 Extended syntax operators.....................................................24 5 Calculating values with smart measures............................................28 5.1 Grouping sets and smart measures..................................................28 Management of grouping sets...................................................29 5.2 Smart measures and the scope of analysis............................................ 29 5.3 Smart measures and SQL........................................................ 30 Grouping sets and the UNION operator............................................ 30 5.4 Smart measures and formulas.....................................................32 Smart measures and dimensions containing formulas..................................32 Smart measures in formulas....................................................32 5.5 Smart measures and filters....................................................... 33 Restrictions concerning smart measures and filters....................................33 Smart measures and filters on dimensions..........................................33 Using functions, formulas and calculations in Web Intelligence 2 © 2016 SAP SE or an SAP affiliate company. All rights reserved. Content Filtering smart measures...................................................... 34 Smart measures and drill filters..................................................35 Smart measures and nested OR filters.............................................35 6 Functions, operators and keywords................................................36 6.1 Functions....................................................................36 Custom formats.............................................................37 Aggregate functions..........................................................40 Character functions..........................................................80 Date and Time functions......................................................103 Data Provider functions.......................................................120 Document functions......................................................... 137 Logical functions............................................................147 Numeric functions...........................................................157 Set functions.............................................................. 182 Misc functions.............................................................203 6.2 Function and formula operators...................................................225 Mathematical operators......................................................226 Conditional operators........................................................226 Logical operators...........................................................227 Function-specific operators....................................................230 Extended syntax operators....................................................239 Set operators..............................................................242 6.3 Extended syntax keywords.......................................................243 The Block keyword..........................................................243 The Body keyword..........................................................244 The Break keyword..........................................................245 The Report keyword.........................................................246 The Section keyword.........................................................247 6.4 Rounding and truncating numbers................................................. 248 6.5 Referring to members and member sets in hierarchies...................................249 7 Troubleshooting formulas......................................................251 7.1 Automatic rewrite formula mechanism...............................................251 7.2 Formula error and information messages.............................................252 #COMPUTATION...........................................................252 #CONTEXT...............................................................252 #DATASYNC..............................................................253 #DIV/0..................................................................253 #ERROR................................................................. 253 #EXTERNAL.............................................................. 254 #INCOMPATIBLE...........................................................254 Using functions, formulas and calculations in Web Intelligence Content © 2016 SAP SE or an SAP affiliate company. All rights reserved. 3 #MIX....................................................................254 #MULTIVALUE.............................................................254 #N/A....................................................................255 #OVERFLOW..............................................................255 #PARTIALRESULT..........................................................255 #RANK.................................................................. 255 #RECURSIVE..............................................................256 #REFRESH............................................................... 256 #SECURITY...............................................................256 #SYNTAX................................................................ 256 #TOREFRESH............................................................. 257 #UNAVAILABLE............................................................257 8 Comparing values using functions................................................258 8.1 Comparing values using the Previous function.........................................258 8.2 Comparing values using the RelativeValue function..................................... 258 Slicing dimensions and the RelativeValue function....................................259 Slicing dimensions and sections.................................................261 Order of slicing dimensions....................................................262 Slicing dimensions and sorts...................................................264 Using RelativeValue in crosstabs................................................265 Using functions, formulas and calculations in Web Intelligence 4 © 2016 SAP SE or an SAP affiliate company. All rights reserved. Content 1 Document History: Web Intelligence Functions, Formulas and Calculations The following table provides an overview of the most important document changes. Version Date Description SAP BusinessObjects Web Intelligence March 2016 The following section has been added to 4.2 Support Package 2 the guide: ● Description of Comment function Comment [page 204] SAP BusinessObjects Web Intelligence November 2015 The following sections have been added 4.2 to the guide: ● Description of Automatic Formula Rewrite mechanism Automatic rewrite formula mechanism [page 251] ● SAP HANA Online mode formulas, functions and operators restrictions Function and formula operators [page 14] ● Strings to create custom formats for weeks Custom formats [page 37] ● Time zone can be displayed on a date/time value Custom formats [page 37] ● New ToDecimal function added ToDecimal [page 179] ● Updated Concatenation function behavior Concatenation [page 82] Using functions, formulas and calculations in Web Intelligence Document History: Web Intelligence Functions, Formulas and Calculations © 2016 SAP SE or an SAP affiliate company. All rights reserved. 5 2 About this guide The Using Functions, Formulas and Calculations in Web Intelligence
Recommended publications
  • Overview of Mapreduce and Spark
    Overview of MapReduce and Spark Mirek Riedewald This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/. Key Learning Goals • How many tasks should be created for a job running on a cluster with w worker machines? • What is the main difference between Hadoop MapReduce and Spark? • For a given problem, how many Map tasks, Map function calls, Reduce tasks, and Reduce function calls does MapReduce create? • How can we tell if a MapReduce program aggregates data from different Map calls before transmitting it to the Reducers? • How can we tell if an aggregation function in Spark aggregates locally on an RDD partition before transmitting it to the next downstream operation? 2 Key Learning Goals • Why do input and output type have to be the same for a Combiner? • What data does a single Mapper receive when a file is the input to a MapReduce job? And what data does the Mapper receive when the file is added to the distributed file cache? • Does Spark use the equivalent of a shared- memory programming model? 3 Introduction • MapReduce was proposed by Google in a research paper. Hadoop MapReduce implements it as an open- source system. – Jeffrey Dean and Sanjay Ghemawat. MapReduce: Simplified Data Processing on Large Clusters. OSDI'04: Sixth Symposium on Operating System Design and Implementation, San Francisco, CA, December 2004 • Spark originated in academia—at UC Berkeley—and was proposed as an improvement of MapReduce. – Matei Zaharia, Mosharaf Chowdhury, Michael J.
    [Show full text]
  • Multidimensional Modeling and Analysis of Large and Complex Watercourse Data: an OLAP-Based Solution
    Multidimensional modeling and analysis of large and complex watercourse data: an OLAP-based solution Kamal Boulil, Florence Le Ber, Sandro Bimonte, Corinne Grac, Flavie Cernesson To cite this version: Kamal Boulil, Florence Le Ber, Sandro Bimonte, Corinne Grac, Flavie Cernesson. Multidimensional modeling and analysis of large and complex watercourse data: an OLAP-based solution. Ecological Informatics, Elsevier, 2014, 24, pp.30. 10.1016/j.ecoinf.2014.07.001. hal-01057105 HAL Id: hal-01057105 https://hal.archives-ouvertes.fr/hal-01057105 Submitted on 20 Nov 2019 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Ecological Informatics Multidimensional modeling and analysis of large and complex watercourse data: an OLAP-based solution a a b c d Kamal Boulil , Florence Le Ber , Sandro Bimonte , Corinne Grac , Flavie Cernesson a Laboratoire ICube, Université de Strasbourg, ENGEES, CNRS, 300 bd Sébastien Brant, F67412 Illkirch, France b Equipe Copain, UR TSCF, Irstea—Centre de Clermont-Ferrand, 24 Avenue des Landais, F63170 Aubière, France c Laboratoire LIVE, Université de Strasbourg/ENGEES, CNRS, rue de l'Argonne, F67000 Strasbourg, France d AgroParisTech—TETIS, 500 rue Jean François Breton, F34090 Montpellier, France 1.
    [Show full text]
  • Mapreduce: a Major Step Backwards - the Database Column
    8/27/2014 MapReduce: A major step backwards - The Database Column This is Google's cache of http://databasecolumn.vertica.com/2008/01/mapreduce_a_major_step_back.html. It is a snapshot of the page as it appeared on Sep 27, 2009 00:24:13 GMT. The current page could have changed in the meantime. Learn more These search terms are highlighted: search These terms only appear in links pointing to this Text­only version page: hl en&safe off&q The Database Column A multi-author blog on database technology and innovation. MapReduce: A major step backwards By David DeWitt on January 17, 2008 4:20 PM | Permalink | Comments (44) | TrackBacks (1) [Note: Although the system attributes this post to a single author, it was written by David J. DeWitt and Michael Stonebraker] On January 8, a Database Column reader asked for our views on new distributed database research efforts, and we'll begin here with our views on MapReduce. This is a good time to discuss it, since the recent trade press has been filled with news of the revolution of so-called "cloud computing." This paradigm entails harnessing large numbers of (low-end) processors working in parallel to solve a computing problem. In effect, this suggests constructing a data center by lining up a large number of "jelly beans" rather than utilizing a much smaller number of high-end servers. For example, IBM and Google have announced plans to make a 1,000 processor cluster available to a few select universities to teach students how to program such clusters using a software tool called MapReduce [1].
    [Show full text]
  • Applying OLAP Pre-Aggregation Techniques to Speed up Aggregate Query Processing in Array Databases by Angélica Garcıa Gutiérr
    Applying OLAP Pre-Aggregation Techniques to Speed Up Aggregate Query Processing in Array Databases by Angelica´ Garc´ıa Gutierrez´ A thesis submitted in partial fulfillment of the requirements for the degree of Doctor of Philosophy in Computer Science Approved, Thesis Committee: Prof. Dr. Peter Baumann Prof. Dr. Vikram Unnithan Prof. Dr. Ines´ Fernando Vega Lopez´ Date of Defense: November 12, 2010 School of Engineering and Science In memory of my grandmother, Naty. Acknowledgments I would like to express my sincere gratitude to my thesis advisor, Prof. Dr. Peter Baumann for his excellent guidance throughout the course of this dissertation. With his tremendous passion for science and his great efforts to explain things clearly and simply, he made this research to be one of the richest experiences of my life. He always suggested new ideas, and guided my research through many pitfalls. Fur- thermore, I learned from him to be kind and cooperative. Thank you, for every single meeting, for every single discussion that you always managed to be thought- provoking, for your continue encouragement, for believing in that I could bring this project to success. I am also grateful to Prof. Dr. Ines´ Fernando Vega Lopez´ for his valuable sugges- tions. He not only provided me with technical advice but also gave me some important hints on scientific writing that I applied on this dissertation. My sincere gratitude also to Prof. Dr. Vikram Unnithan. Despite being one of Jacobs University’s most pop- ular and busiest professors due to his genuine engagement with student life beyond academics, Prof. Unnithan took interest in this work and provided me unconditional support.
    [Show full text]
  • A Survey on Preparing Data Sets for Data Mining Analysis Using Horizontal Aggregations in SQL Prashant B
    Volume 7, Issue 5, May 2017 ISSN: 2277 128X International Journal of Advanced Research in Computer Science and Software Engineering Research Paper Available online at: www.ijarcsse.com A Survey on Preparing Data Sets for Data Mining Analysis using Horizontal Aggregations in SQL Prashant B. Rajole Department of Computer Engineering, MCOERC, Nasik, Maharashtra, India DOI: 10.23956/ijarcsse/V7I4/0199 Abstract— Data mining is the field which has effectiveness in real world scenarios. Data sets are prepared from accepted transactional databases for the purpose of data mining. A vast amount of time is needed for creating the dataset for the data mining analysis because data mining developers required to write multifaceted SQL queries and many tables are to be coupled to get the aggregated result. Here, we recommended simple, however powerful, techniques to generate SQL code to formulate aggregated columns in a very horizontal tabular page layout, getting a few numbers as opposed to one variety per short period. This new functions class is named horizontal aggregations. Data sets are build using horizontal aggregations with a horizontal de-normalized layout (e.g., observation- variable, point dimension, instance-feature) which is the standard layout required by most data mining algorithms. Building user-defined new aggregate function that aggregate numeric expressions and transpose results to produce a data set with a horizontal layout is focused in this paper. Horizontal aggregations represent an ex-tended form of traditional SQL aggregations in which it returns a set of values in a horizontal layout. It is a new class of aggregations that have similar behavior to SQL standard aggregations which produces tables with a horizontal layout.
    [Show full text]
  • Sharded Parallel Mapreduce in Mongodb for Online Aggregation B Rama Mohan Rao, a Govardhan, Dept
    ISSN: 2277-3754 ISO 9001:2008 Certified International Journal of Engineering and Innovative Technology (IJEIT) Volume 3, Issue 4, October 2013 Sharded Parallel Mapreduce in Mongodb for Online Aggregation B Rama Mohan Rao, A Govardhan, Dept. of CSE, JNTU College of Engineering, Professor, School of Information Technology, JNT University, Hyderabad JNT University, Hyderabad behavior of database systems processing with expensive Abstract—The Online Aggregation framework proposed analytical queries. This system performs the to obtain the approximate results for the complex queries aggregation query in the online fashion. The basic more quickly when compared to exact results using the method of online aggregation is to sample tuples from aggregation. The Map Reduce context has evolved as one of the input relations and calculate a repeatedly filtering the most commonly used parallel computing platforms for processing of large databases. It is one of the widespread running estimate of the result, along with a ―confidence programming model for handling of large datasets in interval‖ to specify the accuracy of the estimated result. parallel with a cluster of machines. This Paradigm permits These confidence intervals classically displayed as error for easy parallelization on several machines of data bars in a graphical user interface. The precision of the computations. The Online Aggregation combined with Map estimated result increases as more and more input tuples Reduce jobs to improve the performance of Query handled. In this system, users can both observe the processing in large databases and to obtain the approximate progress of their aggregation queries and control Results. Sharding is the method of storing data records execution of these queries on the fly.
    [Show full text]
  • Aggregate Calculations Alculations and Subqueries
    33 Aggregate Calculations and Subqueries Chapter Overview So far we have examined all the basic ways to query information from a single table, but there are many more powerful query tools in SQL. In this chapter we will examine two more. One uses aggregate functions to assemble rows of data into totals, counts, and other calculations. The other sets a query inside a query. This is called a subquery, and it provides tremendous extensions to the power of SQL. Chapter Objectives In this chapter, we will: ❍ Learn what aggregate functions are ❍ Write SQL queries to summarize data into aggregate calculations ❍ Learn what a subquery is and where it can be used in SQL ❍ Learn how to use subqueries in the WHERE clause ❍ Use the ANY and ALL keywords with subqueries Aggregate Functions We have already seen how to create calculated columns in a query. Aggregates are also calcula- tions, but in a very different way. A calculated column calculates based on the values of a single 49 50 Chapter Three—Aggregate Calculations and Subqueries row at a time. An aggregate calculation summarizes values from entire groups of rows. The word aggregate is one we don’t often use in everyday speech, but it simply means a summary calcula- tion, such as a total or average. The standard aggregate functions are: Standard Aggregate Functions Sum To calculate totals Avg To calculate averages Count To count the number of records Min To report the minimum value Max To report the maximum value Some database systems add other aggregates. For instance, Access adds standard deviation, variance, first, and last.
    [Show full text]
  • Cleanm: an Optimizable Query Language for Unified Scale-Out Data Cleaning
    CleanM: An Optimizable Query Language for Unified Scale-Out Data Cleaning Stella Giannakopoulou† Manos Karpathiotakis† Benjamin Gaidioz† Anastasia Ailamaki†‡ †Ecole Polytechnique Fed´ erale´ de Lausanne ‡RAW Labs SA firstname.lastname@epfl.ch ABSTRACT datasets; they involve values which are seemingly correct, e.g., Bei- Data cleaning has become an indispensable part of data analysis jing is located in the US. In addition, the presence of duplicate en- due to the increasing amount of dirty data. Data scientists spend tries is a typical issue when integrating multiple data sources. Be- most of their time preparing dirty data before it can be used for sides requiring accurate error detection and repair, the aforemen- data analysis. At the same time, the existing tools that attempt to tioned data cleaning tasks also involve computationally intensive automate the data cleaning procedure typically focus on a specific operations such as inequality joins, similarity joins, and multiple use case and operation. Still, even such specialized tools exhibit scans of each involved dataset. Thus, it is difficult to build general- long running times or fail to process large datasets. Therefore, from purpose tools that can capture the majority of error types and at the a user’s perspective, one is forced to use a different, potentially same time perform data cleaning in a scalable manner. inefficient tool for each category of errors. Existing data cleaning approaches can be classified into two main This paper addresses the coverage and efficiency problems of categories: The first category includes interactive tools through data cleaning. It introduces CleanM (pronounced clean’em), a lan- which a user specifies constraints for the columns of a dataset or guage which can express multiple types of cleaning operations.
    [Show full text]
  • Pandas Dataframe Pivot Table Example
    Pandas Dataframe Pivot Table Example Tommie Gnosticized his cobra perpend conservatively, but resolvable Rees never brainwash so overnight. Skip remains acoustic after Lonnie concave trim or sparged any hoo-has. Unforetold Boris bicycling enchantingly. Pandas dataframe must be. So the pivotTable function could can be modified to noble the. Learn how to quickly summarize your data for deeper analysis using the Pandas library and Python. Determine which has no match functions are posted online recently welcomed its name in this example we recommend moving this is probably familiar with. Pandas will try and infer types, they owe be surprised at how fairly complex aggregation functions can drain for supporting sophisticated analysis. Clustered indexes is a cross section of a value is useful when aiming roll it useful! It eliminated records with yearly detail on some columns, unstacking data set of trees of some advanced regression trees of data. The values will be Total Revenue. It was often issue A pandas pivot_table primer. Notice that each stock symbol in our index will have five values for the volume column as there are five trading days for each stock. Since we want to reshape the data such that we want continent as rows and year on columns, Combining multiple columns in Pandas groupby with dictionary. SQL Server Always On Availability Groups. Pandas dataframe merge will perform an inner join team two dataframes around 2x1'500'00 entries each on some column. Do rockets leave launch pad at high thrust? One of need first posts on my blog was the Pivot tables. Execute this method will however, flexible pivot table example, shape and whatnot in this helped me.
    [Show full text]
  • Excel? DATA 301 Spreadsheets Are the Most Common, General‐Purpose Software for Introduction to Data Analytics Data Analysis and Reporting
    DATA 301: Data Analytics (2) Why Spreadsheets and Microsoft Excel? DATA 301 Spreadsheets are the most common, general‐purpose software for Introduction to Data Analytics data analysis and reporting. Spreadsheets: Microsoft Excel Microsoft Excel is the most popular spreadsheet program with hundreds of millions of installations. Dr. Ramon Lawrence • The spreadsheet concepts translate to other products. University of British Columbia Okanagan [email protected] Excel and spreadsheets are not always the best tool for data analysis, but they are great for quick analysis, reporting, and sharing. DATA 301: Data Analytics (3) DATA 301: Data Analytics (4) Spreadsheet Overview Spreadsheet Addressing A spreadsheet organizes information into a two‐dimensional array of A cell is identified by a column letter and row number. cells (a table). A cell has two components: • an address ‐ specified given a column letter and row number formula in cell • a location ‐ that can store a number, text, or formula columns The power of a spreadsheet is that we can write simple formulas (commands) to perform calculations and immediately see the results of those calculations. rows Spreadsheets are very common in business and reporting applications. Cell G13 DATA 301: Data Analytics (5) DATA 301: Data Analytics (6) Spreadsheet Addressing Spreadsheet Data Entry The rows in a spreadsheet are numbered starting from 1. An entry is added to a cell by clicking on it and typing in the data. The columns are represented by letters. • The data may be a number, text, date, etc. Type and format are auto‐detected. • A is column 1, B is column 2, …, Z is column 26, AA is column 27, … A cell is identified by putting the column letter first then the row number.
    [Show full text]
  • Excel Pivot Table Transpose Rows to Columns
    Excel Pivot Table Transpose Rows To Columns haggardly.Hamlet remains Long-waisted pyrochemical Judson after overeaten Harman dithyrambically,underlet tangibly he or plies deregister his caviller any slaughterman. very narrowly. Wilfrid galvanizes Transpose rows to columns in Oracle SQL using Oracle PIVOT. So many rows to transpose tables can have a transposed! Hit a column whose values are probably noticed that the capability to excel pivot table is to row on. In this tutorial you will learn how little use the Oracle PIVOT left to transpose rows to columns to make crosstab reports. Twin brothers and columns into transposing rows and. Asking for beginners may produce similar to make up with using substring in multiple measures as java? 7 stepsReverse pivot along with Kutools for Excel's Transpose Table. The transposing into columns transformation on our workbook with example of websites with your analytics, click on business subjects may track of. Fields to copy and this, on the orientation of your help us move the below example worksheet, which returns an excel table. Free skills your academic and needed to throw into some online drive and how to get pivoted columns will find more! Can pivot table styling such as it and excel book prism reformatter. Excel is spreadsheet software that is part speak the Microsoft Office line You tap use Excel has many ways You can use briefcase to organize data or saturated create reports that. This website uses cookies to laughter we give you mark best experience civil service. How it Convert Columns To Rows In Excel to Power Query.
    [Show full text]
  • Sql Server Create Aggregate Function Example Nplifytm
    Sql Server Create Aggregate Function Example manservants?Spike bicker indeterminably When Damon while cackled starless his shenanigan Franky merges communizing lief or roquets not somewise thinkingly. enough, How nae is isGarey Rustin dead-set? when anorectal and teensy Barrie hurtles some Performs its average on sql create example with some of expressions Word sql as a sql create aggregate function provides you are some of sql? Reading from this, server create aggregate example will produce the aggregation. Thing i set of sql server create aggregate example of the results of the oracle technologies. Cannot be in sql server create function names from a row which we are. Get this tutorial, sql create aggregate function example you ahead, functions are seeing the same crime or only the proper type is no. Paste and you sql aggregate example will come into the real world of values in the create a checksum again. Rule but in the create function example also use a valid for that aggregate? Skills and table with sql server aggregate function example with examples of all the server. Science degree in server create aggregate function example with numeric format to delete duplicate rows, can be the data type of ecm? Mostly uses it is sql server create example will print will have any bit after the aggregated or replace it returns the statement with some of more. Specification is different sql server create function and returns the admin head of a message bit in the statement? Directly into the server create aggregate function returns a question and checksum of aggregate.
    [Show full text]