Forum Discussion
two questions regarding voucher conversion rate analysis
Hey there, I am completely new to Power BI Desktop. So it was hard to find a subject for that - sorry.
The initial situation
The data is from a membership-site we want to analyse. In this case it is about conversion rates for users signing up with a voucher.
For this need we have two tables with data:
- Table A - a list of voucher redemptions
- Column "Redeemed on date/time"
- Column "User-ID"
- Column "voucher code"
- Table B - a list of transactions (payments) made by a user after using a voucher
- Column A "Redeemed on date"
- Column B "User-ID"
- Column C "voucher code"
- Column D "transaction date"
- Column E "transaction value"
- Column F "days between column A and column D"
- Column G "60-day-conversion"
- "Yes" if column F is between 1 and 60 days
- "No" if not
The point that makes my two struggles so hard for me is that I think I have to work with the two values of "User-ID" and "voucher code", as this combination is guaranteed to be unique in table A. But not so in table B, as a user(-id) who used a special voucher code, could have done several payments later (with a monthly subscription for example), so the combination of "User-ID" and "voucher code" does exist several times in table B.
What I want to do next - and need your help for it
Two things (and my thoughts about it - but please be free to advise me any other direction):
1. I want to add a column "60-day-conversion" to table A (list of voucher redemptions) with the value of the column of the same name in table B (transactions) (column G) for the combination of a user-id and a voucher code.
So I think in pseudocode I would have to say in table A: Create a new column named "60-day-conversion" with the value from the first row in table B that has the same values in columns "User-ID" and "voucher code" as we have it in the corresponding fields in table A.
values as an example can be:
- 60-day-conversion | "Yes" or "No"
- User-ID | 685421
- voucher code | 30daysfree-summer2020
2. I want to add a column "total value" to table A (list of voucher redemptions) with the SUM of the values of the column "transaction value" of all the rows who have the same "user-id" and "voucher code" in table B as the unique row in table A.
I hope I have been able to explain what I need to do and need help for in an understandable way. Of course I am open to all ideas and approaches and available for questions from you.
Thank you very much!
Michael
3 Replies
- TomMartens
Super User
Hey voitmichael ,
thanks for the detailed explanation, and welcome to this community.
As you will start answering some questions, you will realize that it will help to touch the data 🙂 For this reason I ask you to create a pbix that contains sample data but still reflects your data model (here both tables). You can use the feature "Enter Data" (Enter data directly into Power BI Desktop - Power BI | Microsoft Docs), or create the data using an Excel file.
Upload the pbix with the sample data to onedrive or dropbox and share the link, if you are using Excel to create the sample data, share the xlsx as well.
Regards,
Tom
- voitmichaelNew Member
Hey there, tried to do it, but I would have to build everything new or I have to reveal sensitive data as I am able to change the values to sample data but not the headers - and they alone tell a lot how we are working. If I remove or rename one of the headers in the csv files, I get errors thrown in Power BI Desktop. But I can't reveal that information.
Is my question bad written or otherwise hard to understand?
Will have one more try to build a sample version later this day...
- v-kelly-msft
Community Support
Hi voitmichael ,
Sample data could make it easier for us to understand your request,also it could save time from both of you and us to get the result as you need.
Thanks for your time to provide the sample data.
Best Regards,
KellyDid I answer your question? Mark my post as a solution!