Help with making a section in the app

How many days do you want to see at a time? One week? One month? The entire sheet?

What if you could select a month like “January” and see all the totals for the days in January. Would that work?

No that wont do it. I need the total for each day.

Yes I understand. The total would be by each day. How many days do you need to see on screen at one time?

Would it work if you select January and see all the days in January or select February and see all the days in February?

1 Like

Yeah that won’t be a problem.

Done:

2 Likes

:crown:

Wow this is kind of it

1 Like

How do I do it ?

You have to generate a JSON file from the data and use JavaScript to sum the same dates.

could you provide me a copy of your work ?

I still kind of don’t understand the ultimate desired outcome here. Is it basically just a sum of each day’s sales?

This looks to me like it should simply be a trunc(date) in a math column, a template to join the date with the user, then a relation linking the template to itself. Follow that with a rollup to sum the total for each user per day.

Possibly combined with the logic to only show the sum in unique rows and a filter the list to those unique rows.

Haven’t really studied the problem here, but seems easily doable without getting into javascript.

1 Like

That’s how I understood it… just a sum of each days sales. I was thinking along the lines of what @Jeff_Hager just suggested and additionally add a choice component to filter the relation by month.

2 Likes

Yeah, I don’t understand why there needs to be a more complex solution than a relation + rollup here.

I would love to se the easy sololution to reproduce my App JavaScript, i think you gonna have to craete a spider web of relations, rollups and if else columns :wink:

Isn’t this the same result?

3 Likes

That is a perfect solution @ThinhDinh. I forgot that you could sum relations! And it has 1 column less than mine, LOL… Good Job!
But I still prefer JavaScript and transforming data to JSON. It will give more options for advanced calculations and filtering, It is just way easier to deal with JSON.

2 Likes

19 Columns but I included a choice, running total and a list collection :wink:

3 Likes

19 columns… LOL. You have a lot of time to spare :wink:

1 Like

Trying to earn my keep amongst legends… :nerd_face:

The majority of the bulk is in the running total. In the past I’ve tried JavaScript for a running total but there were some edge cases where it broke.

I do think JavaScript is a very valuable tool and I need to learn more. Will you teach me some of your ways @Uzo?

1 Like