function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jason ZuziakJason Zuziak 

wave trail hands on challenge

I am unable to complete the hands-on challenge "Create a lens that shows which industry is buying the most laptops" I continue to receive the following error even after multiple attempts.

"Challenge Not yet complete... here's what's wrong: 
The 'Top Laptop Industry' lens does not appear to have the correct query. Please check the requirements and ensure everything is setup correctly."
Alap MistryAlap Mistry
Hello Jason Zuziak,
Can you post screenshot of lens which is configured by you?
Regards,
Alap Mistry
Jason ZuziakJason Zuziak
Screenshot
Jessica Eiselman 3Jessica Eiselman 3
I'm running into the same error message. Any help would be appreciated. Thanks.
Alap MistryAlap Mistry
Hello Jason Zuziak and Jessica Eiselman 3,
Are you both saved lens in "My Exploration" App? If yes, then delete that lens and create once. If no, then then save it in "My Exploration" App.
If error is occur, then post here. If it is useful, then mark it as best answer (for close this thread).
Regards,
Alap Mistry
Jessica Eiselman 3Jessica Eiselman 3
Thanks, Alap. I did save it in "My Exploration" and tried deleting and creating a new one and it still didn't work. :(
Rob BaldassareRob Baldassare
Same problem here.  Deleting and redoing it did not solve it.
Dieter RoskoniDieter Roskoni
Hi I am having the same issues. I did it now 3 times and checked everything but still receiving this error
Othmane MikouOthmane Mikou
Greetings,
I am running into the same problem, I have deleted it and re-created it at least four times and it didn't solve the problem.
Anybody has any thoughts what is wrong with that?
Damilola Adeyemi 9Damilola Adeyemi 9
I am having the same problem and it is very frustrating- having worked this hard, trying to confirm answer and it not working, three hands-on with similar errors. it is very demoralizing. Please fix this issue. 
Damilola Adeyemi 9Damilola Adeyemi 9
finally, I got it to work 
Othmane MikouOthmane Mikou
how did you get it to work? would you please walk us through the process? I have been repeating it multiple times, but still getting error, which is preventing me from making progress on this superbadge
Tiago Abrantes 9Tiago Abrantes 9
I may be coming to late but the order of configurations realy matters. Even the chage Measure as to be done in that exact order, after second group. Really  don't mess with that order.

 
Nicole FritzNicole Fritz
Hello,

I am receiving a similar message:

Challenge Not yet complete... here's what's wrong: 
The 'Trailhead_Data_Manager' app was not found. Please follow the requirements and ensure the wave enabled org is setup correctly.

When I go to my hands-on challenge, there is not a challenge for me to complete. Am I missing a step?

Thanks!
Thiago Ferraz 5Thiago Ferraz 5
Hello, I got the same problem and my query looked correct -- but I knew that I had added the "Product Name" Group By first mistakenly (before adding the "Industry" Group By). Even though I deleted the "Product Name" group by (so that Industry was now first), and then re-added it, I got the malformed query error above.
I deleted my lens, started from scratch, and all worked well.

In other words, you cannot modify an existing lens to pass this challenge, but must start a new lens from scratch, and apply each of the steps in the order directed in order to pass the challenge. 
Doug DunfeeDoug Dunfee
Anyone who might still get this, please see my response on this aggreate post.  https://developer.salesforce.com/forums/?id=9060G000000BcUBQA0
Lance DayLance Day
I also had to delete and recreate from scratch placing things in the order specified.  The first time I built it out, I built it while ready the paragraph which is not the same order.....Salesforce Trailhead team really needs to give some slack on how it analyzes the queries here!!!!!
akash_dev__cakash_dev__c
Hi All,

I was getting the same error again and again. Apparently the order matters.

Follow the steps in the order as they have been defined in the challenge... I have followed the same approach, instructions and as the result I have cleared the challenge...

steps: 

Dataset: DTC Opportunity
Chart Type: Stacked Bar
Bars: Industry
Bar Segments: Product Name
Bar Length: Sum of Amount
Sort: Descending
Filters: Product Family Laptops
Filters: Won true
Lens Name: Top Laptop Industry
App: My Exploration

follow these steps one by one and if you are having any pre added lenses in your My Exploration app then delete all of them and save the current lens and run the app. 

Below is the query: 

q = load "DTC_Opportunity_SAMPLE";
q = filter q by 'Product_Family' == "Laptops";
q = filter q by 'Won' == "true";
q = group q by ('Industry', 'Product_Name');
q = foreach q generate 'Industry' as 'Industry', 'Product_Name' as 'Product_Name', sum('Amount') as 'sum_Amount';
q = order q by 'sum_Amount' desc;
q = limit q 2000;

Thanks and Regards,
Akash Garg

Please like and share if I am able to help you with my answer.
Jyoti Gaur 16Jyoti Gaur 16
Hi All,

I also faced same issue and tried to solve it, but suddenly I read out the whole assignmnet one more time and found that the order of steps are most important.

I think If we follow ordering of the steps as it is mentioned in the challenge, it will resolve your problem.

Thanks.
Ranjeet BhoyarRanjeet Bhoyar
Trailhead bots checks the end query.

Following are two different queries resulting same Lens visualisation

Query when you select Won as first filter and Product Family as Second filter

q = load "DTC_Opportunity_SAMPLE";
q = filter q by 'Won' == "true";
q = filter q by 'Product_Family' == "Laptops";
q = group q by ('Industry', 'Product_Name');
q = foreach q generate 'Industry' as 'Industry', 'Product_Name' as 'Product_Name', sum('Amount') as 'sum_Amount';
q = order q by 'sum_Amount' desc;
q = limit q 2000;

Query when you select Product Family as first filter and Won as Second filter

q = load "DTC_Opportunity_SAMPLE";
q = filter q by 'Won' == "true";
q = filter q by 'Product_Family' == "Laptops";
q = group q by ('Industry', 'Product_Name');
q = foreach q generate 'Industry' as 'Industry', 'Product_Name' as 'Product_Name', sum('Amount') as 'sum_Amount';
q = order q by 'sum_Amount' desc;
q = limit q 2000;

Second query is what trainlhead bots are expecting, Therefore, you may correct the sequence of the filters to pass the challange.

Please mark this as answer if this solves the issue.
Christine PrestonChristine Preston
There is still an isseu with this. I have followed everythig to a T & am still receiving the error.  Any help would be awesome 
ranjeet bhoyar 25ranjeet bhoyar 25
@Christine, Can you share the Query resulting fro, Lens Visualisation?
Christine PrestonChristine Preston
{
    "name": "Top_Laptop_Industry",
    "label": "Top Laptop Industry",
    "description": "Top Laptop Industry",
    "visualizationType": "stackhbar",
    "state": {
        "steps": {
            "aggregateflex": {
                "type": "aggregateflex",
                "query": {
                    "measures": [
                        [
                            "sum",
                            "Amount"
                        ]
                    ],
                    "groups": [
                        "Industry",
                        "Product_Name"
                    ],
                    "order": [
                        [
                            "sum_Amount",
                            {
                                "ascending": false
                            }
                        ]
                    ],
                    "filters": [
                        [
                            "Product_Family",
                            [
                                "Laptops"
                            ],
                            "in"
                        ],
                        [
                            "Stage",
                            [
                                "08 - Closed Won"
                            ],
                            "in"
                        ]
                    ]
                },
                "visualizationParameters": {
                    "visualizationType": "stackhbar",
                    "options": {}
                },
                "datasets": [
                    {
                        "id": "0Fb3k000000KzToCAK",
                        "label": "DTC Opportunity",
                        "name": "DTC_Opportunity_SAMPLE",
                        "url": "/services/data/v46.0/wave/datasets/0Fb3k000000KzToCAK"
                    }
                ],
                "useGlobal": true,
                "isGlobal": false,
                "selectMode": "multi",
                "broadcastFacet": false,
                "receiveFacet": false
            }
        },
        "widgets": {
            "aggregateflex_chart": {
                "type": "chart",
                "parameters": {
                    "visualizationType": "stackhbar",
                    "autoFitMode": "keepLabels",
                    "theme": "wave",
                    "step": "aggregateflex",
                    "showValues": true,
                    "legend": {
                        "descOrder": false,
                        "showHeader": true,
                        "show": true,
                        "customSize": "auto",
                        "position": "right-top",
                        "inside": false
                    },
                    "axisMode": "multi",
                    "totalSumMode": "none",
                    "tooltip": {
                        "showBinLabel": true,
                        "measures": "",
                        "showNullValues": true,
                        "showPercentage": true,
                        "showDimensions": true,
                        "showMeasures": true,
                        "customizeTooltip": false,
                        "dimensions": ""
                    },
                    "exploreLink": true,
                    "title": {
                        "fontSize": 14,
                        "subtitleFontSize": 11,
                        "label": "",
                        "align": "center",
                        "subtitleLabel": ""
                    },
                    "trellis": {
                        "flipLabels": false,
                        "showGridLines": true,
                        "size": [
                            100,
                            100
                        ],
                        "enable": false,
                        "type": "x",
                        "chartsPerLine": 4
                    },
                    "columnMap": {
                        "split": [
                            "Product_Name"
                        ],
                        "trellis": [],
                        "dimensionAxis": [
                            "Industry"
                        ],
                        "plots": [
                            "sum_Amount"
                        ]
                    },
                    "showActionMenu": true,
                    "measureAxis2": {
                        "sqrtScale": false,
                        "showTitle": true,
                        "showAxis": true,
                        "title": "",
                        "customDomain": {
                            "showDomain": false
                        }
                    },
                    "measureAxis1": {
                        "sqrtScale": false,
                        "showTitle": true,
                        "showAxis": true,
                        "title": "",
                        "customDomain": {
                            "showDomain": false
                        }
                    },
                    "normalize": false,
                    "dimensionAxis": {
                        "showTitle": true,
                        "customSize": "auto",
                        "showAxis": true,
                        "title": "",
                        "icons": {
                            "useIcons": false,
                            "iconProps": {
                                "fit": "cover",
                                "column": "",
                                "type": "round"
                            }
                        }
                    },
                    "applyConditionalFormatting": true
                }
            }
        }
    },
    "datasets": [
        {
            "id": "0Fb3k000000KzToCAK",
            "name": "DTC_Opportunity_SAMPLE",
            "label": "DTC Opportunity",
            "url": "/services/data/v46.0/wave/datasets/0Fb3k000000KzToCAK"
        }
    ]
}
Ekta Gupta 43Ekta Gupta 43
i was getting stuck as well . THen i deleted it and followed steps as it is as mentioned that make it so easy to clear. 
Nilambari Suryawanshi 1Nilambari Suryawanshi 1
Hi @Akash Garg,
Thanks your solution helped me.
@All, Usually there is need to follow order in executing steps, as well do remove count or rows , as it impacts query.
which results in giving the error.

 
幹 吉田幹 吉田
User-added image
For those who are stuck on this module, this is the best solution I got to pass the check. As mentioned on the image, you will work on selecting DTC Opportunity first, which is remarked as 'START HERE!!'.
next, need an exact order. select chart type, bars, bar segments, bar length, sort, filters, lens name and app.
Skipping any step and return to the step causes error checks. Careful