FAQ: Usage Funnels - Build a Funnel from Multiple Tables 4

This community-built FAQ covers the “Build a Funnel from Multiple Tables 4” exercise from the lesson “Usage Funnels”.

Paths and Courses
This exercise can be found in the following Codecademy content:

Data Science

FAQs on the exercise Build a Funnel from Multiple Tables 4

There are currently no frequently asked questions associated with this exercise – that’s where you come in! You can contribute to this section by offering your own questions, answers, or clarifications on this exercise. Ask or answer a question by clicking reply (reply) below.

If you’ve had an “aha” moment about the concepts, formatting, syntax, or anything else with this exercise, consider sharing those insights! Teaching others and answering their questions is one of the best ways to learn and stay sharp.

Join the Discussion. Help a fellow learner on their journey.

Ask or answer a question about this exercise by clicking reply (reply) below!

Agree with a comment or answer? Like (like) to up-vote the contribution!

Need broader help or resources? Head here.

Looking for motivation to keep learning? Join our wider discussions.

Learn more about how to use this guide.

Found a bug? Report it!

Have a question about your account or billing? Reach out to our customer support team!

None of the above? Find out where to ask other questions here!

The query for this exercise doesn’t produce any results in the query display. Is anyone else having problems with this lesson? I am not really understanding how the “funnel” is working as I can’t see the results. I continued on anyway and got to the Warby Parker project and at the exact same spot where you have to build a funnel the query for this project didn’t work either. Can someone help?

1 Like

Could you post a link to the lesson?

Here is the link, I have watched the project walkthrough video, used the solution code, and my own code and I get no results in the query display panel. Anyone else having that problem? I had the same problem with the code in the Mattresses and More Lesson Step 9 code. I wrote the correct code, ran it, and nothing displayed.

https://www.codecademy.com/paths/data-science/tracks/analyze-data-sql-analyze-real-data/modules/analyze-data-sql-usage-funnels/projects/analyze-data-sql-usage-funnels-with-warby-parker

I just tried the first task, and did receive output in the console. Which browser are you using?

Safari. I have been getting output all along, it’s just when I hit that specific task, and the one in the Warby Parker that is similar and uses Funnels, nothing. I’ll try Chrome.

I use Firefox most of the time without issue. I use Chrome occasionally, and have had no issues with it either. I’m not a ‘Mac’ guy, so I’ve not used Safari. This Troubleshooting Guide may be of some assistance.

Thanks, I’ll check out the guide. I did try the same exercises with Chrome and still the same problem. Just to be clear, you ran the code for the Mattresses and More Lesson step 9 of 10 and got output in the Query Display? Could you post your code?

No. I only tried the first step in the Usage Funnels With Warby Parker project. I haven’t gone through all of the SQL courses. If you can post a link to the Mattresses and More lesson, I’ll try to get to it later today.

Okay that makes sense. Yes, in the Warby Parker project I linked to above, I do receive output for the Task steps 1-4, it’s when I do task 5 with the 3 Table Join that I receive no output or results. That’s the step I am wondering if you could try for me to see if you get anything. So, same link to the project above, just Task 5.

2 Likes

Ok. It will be later today at the soonest, but I’ll get to it. :slightly_smiling_face:

Ok. I’ve completed the Warby Parker Project and the entire Usage Funnels (Mattresses and More) lesson that you referenced. I had no issues with the results being displayed in any of the tasks. The only times my code failed to yield results were when I had an error that needed to be corrected. Since you were able to see the results in all but a couple of cases, I suspect that your code is the issue. If you would like to post your code, I’d be happy to have a look.

So as it turned out, I contacted support and there was an issue with the Mattresses and More code solution that was causing a problem and they emailed me back with the correct code and mentioned at that time (day we were having the conversation) that they fixed the code. As for the Warby Parker code, I had sometable.user.id instead of sometable.user_id. So I was 1 for 2, lol. Thanks for your help.

2 Likes

In the context of this exercise, how could i modify this query grouped by date (yyyy-mm-dd) to return grouped by year-month instead?

Why you need to use this code:

1.0 * SUM(is_purchase) / SUM(is_checkout) AS ‘checkout_to_purchase’

And this code bellow doesn’t work:

ROUND(SUM(is_purchase) / SUM(is_checkout),2) AS ‘checkout_to_purchase’

The second expression doesn’t work because you have to multiply the result of the expression by 1.0 just before you rounded it. It’s necessary because you’re adding and dividing two integers, therefore the result of expression will be an integer too. In SQL when you divided two integers it tend to round down the result. In this case, especifically, the result would be less than 1, then it will be rounded to 0. Because that, you have to multiply to 1.0 in order to cast the integer to something like float if I didn’t get it wrong. You also can multiply the result per 100. If you multiply per 100 you’ll obtain something like 20, instead of 0.20.

1 Like

How do you complete Step 2 of this exercise? I have plugged in the output into Google Sheets or Excel. However, I cannot manually click the checkbox in Codecademy to mark the step as “Complete.”

3 Likes

Never mind. I figured it out. You MUST click the “Copy to Clipboard” icon. Instead, I manually dragged my pointer to highlight the results, and clicked Ctrl-C and Ctrl-V on my Mac. Codecademy seems to want you to click the “Copy to Clipboard” icon, or you get no credit.

9 Likes

I am really stuck on number 9, last question, I can not figure it out. The query I keep entering is telling me it is incorrect but I am pretty sure it is correct. Can anyone assist please?

Hello, @the_g1016.

We could try, if you’d like to provide the query in question along with the error message you are receiving.