Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [saql]

SAQL - Salesforce Analytical Query Language

0
votes
0answers
8 views

Wave Analytics JSON Filter SAQL

I have a problem when editing a SAQL in wave. When I edited SAQL and update the chart the curreny symbol and comma is remove. Is there a way to add the currency and the comma. What I already did is ...
0
votes
0answers
11 views

Do Einstien Analytics Support Long text area field filter

I have a saql which is filtered using Long Text Area. When I remove the field the query is working fine but when it is included, it is throwing this error Query Exception is failing Please find ...
0
votes
0answers
13 views

Co-group fields from three objects in Wave Analytics

I have three objects viz., qACC , qCON and qOLC. Now from these three objects, I have different fields as follows qACC- 'Country', 'Year','Month'; qCON- 'Country__c','PROC_YR','PROC_MO'; qOLC- '...
0
votes
0answers
15 views

Add Custome Relative filter Einstein Analytics studio

Is it possible to add another choice on the date filter? like creating new Section Called "Date Ranges". Under "Date Ranges" we have choices like "S1", "S2", or "S3". If I select S1 it will filter ...
0
votes
0answers
21 views

Migration of Old Wave Dashboard to new Dashboard

As salesforce old wave dashboards are getting expired in June'19, we have around 19 dashboards to convert to new dashboard design. As the old widgets and other components are not editable in old ...
1
vote
1answer
337 views

SAQL vs SOQL vs SOSL vs SQL? [closed]

I have recently come across SAQL and I'd like to understand the differences between all the different ways to query against Salesforce APIs. The new einstein branding is too complex to get my head ...
0
votes
1answer
85 views

How to check “does not contain” in saql?

I have written my saql like q = load "Opportunities"; q = filter q by !('Opportunity.Name' in ["test","TEST ","Test"]); q = group q by 'Opportunity.Name'; q = foreach q generate 'Opportunity.Name' ...
1
vote
1answer
101 views

Date format in SAQL

I have a requirement in Wave Analytics where I need to fetch records from Previous year when current year is completed. I have a field named Processing Year. It now fetches 2017 records which we have ...
0
votes
0answers
36 views

Need help in SAQL - computeRelative Transformation

Context - running a report on caseHistory object, where data is grouped by caseId (ascending) and then Date/time difference of CreatedDate and previous rows CreatedDate has to be captured at each row ...
0
votes
1answer
57 views

Salesforce Analytics (SAQL)

I would like to pass current year( ["current Year"]) and current month ( ["current month"]) as the dynamic value for month and year instead of the hard coded value . Please let me know how I will ...
0
votes
0answers
39 views

Add row numbers to Query in Wave

I'd like to be able to add a column in to display a row number and summary in Wave SAQL. I have the summary but I can't find anything to help me display the row. Is this possible and if so how can I ...
4
votes
1answer
83 views

After modifying dashboard SAQL in template downstream apps fail to create

What we have done: Created a trivial Einstein Analytics app with the most simple dataflow and dashboard. Created a template for this app Successfully created a (downstream) app from this template (to ...
1
vote
1answer
130 views

SAQL: How to group by string field on whether it is NULL or NOT NULL

As mentioned in the subject I need to group a string field's data by whether its empty or not empty. How can I do this with SAQL? Do I need to create a boolean variable? and group by that?
1
vote
0answers
118 views

Einstein Analytics Binding statement for Year to Date where date is listselector

I have a list selection for Production Date (Year--Month for ease of selection). I have a number that is the credits that should be filtered year to date based on the selected Production Date. I ...
2
votes
3answers
115 views

Dealing with Daylight Savings Time in Einstein

I'm in the UK and having issues importing dates into Einstein due to them being in UTC format while we're currently in UTC+1 due to Daylight Savings Time. I know I need to add some compute nodes to my ...
0
votes
0answers
102 views

Static Filter in SAQL

I wrote a SAQL query with a joined dataset and I want both the left and right datasets to to be filtered dynamically using another widget's selection value. example: q = filter q by 'Account-Name' ...
0
votes
0answers
28 views

SAQL Date PY-MTD

I'm having trouble with relative dates. Problem is I don't understand how those dates are translated into absolute values. Looks like my second param is effectively less than the first... Here is my ...
0
votes
0answers
117 views

Error when trying to loop through a SAQL query in apex

I'm trying to loop account ids through a SAQL query and store the results from the query into a list. However in the loop, the query executes for only the first id in the list fetched, for the second ...
0
votes
1answer
193 views

Group is not a dimension 'Field__c'

Hello I have the following problem, in Analytics I try to group my data set for a specific field and it does not allow it, I get an error Group is not a dimension 'Field__c' What is this error? ...
0
votes
2answers
226 views

It is possible to make a sum under some criteria Wave Analytics

I'm stuck with a problem and I want to make a sum only under certain criteria, for example: Add the Total field per month and then take the average of the last 3 months ie sum (total) -> if month = ...
0
votes
0answers
22 views

Place a Dynamic Text on the Wave Analitycs designer

I am designing a report in analytics and I have found the problem that I can not find the way to place a dynamic Text on top of a table. If I press ctrl + e I see the json of the dashboard but I do ...
0
votes
1answer
27 views

How to prevent a filter in the UI from affecting one of my tables

I have the following problem. I have a Data Set A in which I have created several charts with their tables. There is a filter panel at the top where any change you make to these filters is reflected ...
2
votes
0answers
104 views

Faceting Not Working Within Dataset - Einstein Analytics

I am editing a dashboard in Einstein Analytics. It contained 5 charts, all from the same datasource, and they all faceted between one another when selections were made. I was asked to change the top ...
0
votes
0answers
170 views

Excluding 0 and null values

I am unable to exclude null values with the following coding: q_A = filter q by 'Product_Code__c' in ["1234'] && 'Exact_Total__c' > 0 && 'Exact_Total__c' is not null; I have also ...
2
votes
2answers
149 views

Can complex (Variance) analysis be done in Einstein Analytics?

Background Every month we copy revenue data in our from their original objects (complex normalized tree of related objects) into something we call a snapshot. A denormalized flat table (Custom object)...
0
votes
1answer
316 views

Change chart color from a step using a SAQL query

In Einstein Analytics, is it possible to change the colour of the bars of a horizontal chart, when the step uses a SAQL query and measure bindings? I'ved tried modifying the XMD, however it doesn't ...
1
vote
0answers
30 views

SAQL - Unnest Array to Rows [closed]

Is there a way using SAQL to unnest an array into multiple rows? For example, my output is ['abc', 'def', ghi'] and I would like to end up with 'abc' 'def' 'ghi'
0
votes
1answer
68 views

How to get row with rows salesforce opportunity id from a dataset of Opportunity History(Left) and opportunity(Right)

Below is the SAQL being tried by me. q = load "RELAOpportunityDataset"; q = filter q by 'Opportunity.OpptyRecType.Name' == "RELA Opportunity"; q = foreach q generate q.'Opportunity.Id' as '...
0
votes
1answer
321 views

Conditional Highlighting for Widget in Einstein Analytics

Is it possible to create a conditional highlight in Einstein Analytics I have this following query: q = load "Santher2_new"; result = group q by 'categoria'; result = foreach result generate q.'...
0
votes
2answers
748 views

how to create a bucket field, percentage in wave

Currently I have a dataset that is all opportunities. I generated a dashboard and in there I have report/graph that is all the opportunities grouped by a field called channel__c In salesforce I ...
0
votes
1answer
63 views

CoGrouped Step wont filter other steps

I have the following step built by co-grouping 2 datasets on their SIC codes so that the display shows the sum of Amount for each SIC Code Description. This works as I need it to. q1 = load "...
1
vote
1answer
158 views

SAQL sort without including field in the return results

I need to sort by a field in a SAQL query, but I do not want that field to appear in my results. For example, I am trying to do this q = load "xxx"; q = foreach q generate 'account_id' as '...
0
votes
1answer
342 views

“No results found” data type for Wave

I'm trying to do some basic error handling in SAQL. We have a binding that gives as a result "No result found" both in the SAQL editor and in the actual step. I'm trying to capture the data type of ...
1
vote
2answers
859 views

Using variables in SAQL

I'm trying to basically work with SAQL using some sort of variable. Not sure why every time I do that, I receive an error that the Identifier can't be found. So, let's suppose I want to divide the ...
2
votes
1answer
94 views

Assign bindings to variables

I'm working on a Einstein Analytics project, and I'm trying to get some bindings to be assigned to variables. "q = load \"Dataset\"; _value = foreach q generate ({{cell(S_Amount__1_USD.result, 0, \"...
0
votes
1answer
140 views

How to edit step-calculated metric formats?

When metrics are calculated from a step, and not in the source database, how can the format the calculated metric be edited? Perhaps the JSON or the XMD (where would this live for the calculated ...
1
vote
1answer
2k views

In Wave/Einstein analytics, is it possible to combine query results from 2 different datasets into the same visualization?

I am creating charts/tables on a Wave Dashboard using a small number of datasets that I've created using dataflows and recipes. What I want to do now is to query (i.e., somehow get data) from two of ...
1
vote
1answer
673 views

Analytics Wave - Order by Case Statement

Is it possible to Order a SAQL query using a case statement? We changed CloseDate_Month in to text so it displays as month name instead of month number, but when that's used in the order by, it order ...
0
votes
1answer
503 views

Wave Einstein Analytics filter relative dates in dataflow with filter node

I need to filter opportunities in my dataflow that have a date 'last month' to 'end of current year'. I cannot use filters in the sfdcDigest node as I am doing a couple of calculations later that need ...
0
votes
1answer
174 views

SAQL- How to group by AccountID and report the first value in a table?

I am currently looking to de-duplicate data in a dataset. Reason being, I need to group together all accounts reporting on a criteria, so we may then sum and total the values of each account to get an ...
1
vote
1answer
280 views

SAQL - When I dynamically create dates in SAQL and group them, I can't use the “Timeline” chart

I try to create a timeline chart for every year for products on the market that are started to sell before that year and ended to sell after that year. To get my filtered data I filter them like I ...
0
votes
0answers
51 views

How to write test classes for wave analytic Wave Data Set - SAQL

Can anyone help me with sample test class or approach for test class of Wave dataset. My dataset id in original class is kept in custom metadata. I need to understand how to create data in test class ...
0
votes
2answers
877 views

SAQL Using Current year and doing calculations with dates in a Formula Condition

I want to do calculations with dates and use 'current year' in a formula condition. When I tried to manipulate dates in a formula I always receive an error of incompatibles types; NUMBER AND DATE. ...
0
votes
1answer
1k views

SAQL- Wave analytics Convert to number [duplicate]

Is anyone knows how to convert date or string to a number in SAQL? specifically convert this: toString(now(), "yyyy") into number
1
vote
1answer
552 views

Change Time Zone in Wave Dashboard

I am using page 28 of this doc for reference: https://resources.docs.salesforce.com/200/latest/en-us/sfdc/pdf/bi_dev_guide_saql.pdf I need to change the time zone in the step. I am trying to use the ...
1
vote
0answers
50 views

Wave - Using Times as a Group

I am attempting to build a dashboard using times in the format hh:mm:ss AM/PM. I have tried to do this several different ways include adding a date to the time (even though I don't need that because ...
0
votes
3answers
2k views

How to convert decimals to a percentage in Wave Saql query result

I want to show the reuslt with the percentage, what should I do?
0
votes
2answers
400 views

Incompatible types: STRING and NUMERIC

I'm attempting to change the dates on some data within Wave Analytics to get the correct time zone showing, but I'm getting the error "Incompatible types: STRING and NUMERIC" whenever I attempt the ...
0
votes
2answers
194 views

Perform measure calculation with the saql compact form

for the step clause "measures" using the saql compact form, is possible to make arithmetical calculation like sum(AMOUNT)/sum(WEIGHT) without a compare table? The following example explain what i mean:...
2
votes
1answer
438 views

Wave REST API returns BAD REQUEST ERROR 400

public class SendWaveUsingRESTAPI { private final String clientId = 'xxxx'; private final String clientSecret = 'xxx'; private final String username = 'xxxxx'; private final String password = '...