You ever have a Knack database table/grid view (in the live app) where you want to sum a percentage column? You know, so the sum is at the bottom of the table. Well, it doesn't do it, and it is supposed to. Knack has the sum option specifically for that percentage field's column settings. Here I look in to this issue, and provide a workaround. Please check it out.
Here's an other post that you might like: https://www.knackbuilders.com/post/20-minute-knack-crm
Interested in my Knack database app services? ... Book a call with me here: https://calendly.com/daveparrish/callwithdave
0:00 Hey folks back with another video here. I'm just gonna dive right into this one again. Please like the YouTube channel if you can The videos, but here's today's topic I ran into this the other day. 0:14 I think I've run into it before When you have a table and you want to sum percentages at the bottom. 0:21 I'll show you. It doesn't do it watch this Here's a table This this has agents. Just this just stuff. I just made up The total deal on these are commission records on the total commission for the whole deal and then the split allocation between the agents say 40 60 We want to sum this up I'm gonna be 0:47 right back and tell you the deal what's going on what I think is going on and the work around so give me a minute here
0:00 Okay, folks. Let's figure out what's going on with this sum percentage stuff. I'm gonna go back This is the one that doesn't sum and let's go look at the field. 0:11 That's right here Agent allocation, this is standard number field that we tell it to be a percentage, one of those options. 0:23 Use it regularly. So here it is and let's go to that view Let's go here. Here's that commission record, or the commission records. 0:40 Allocations, let's go to that field. And I've enabled inline editing on this. And I've also told it to sum at the bottom, right, that's what we want. 0:51 And I told it not to sum this total commission because it's the same for the whole deal. So that doesn't get summed. 0:57 But this is our allocation one. And it's got it, allow summary. It wants to behave, it wants to do what we're asking. 1:04 Yes, allow summary. Uhm, but it's not doing that. Go back here. Let's zoom in. Okay. So it's not giving us a sum. 1:19 I don't know why. Support about this. They had some suggestions. One of the reasons I'm doing this video. They said it might be because This percentage symbol's in there And it's getting confused. 1:32 There's definitely something wrong on xn which they'll eventually fix but but This symbol here. I don't know about that because there's a dollar symbol here and it can do that So my point is it's not working if you need it summed your percentages there's a workaround and i'm going to show you this Let's 1:50 go back to data. I did another Table same fields, but a different setup on an allocation agent allocation You may know what i'm getting at No decimals What I want it instead of telling it to be a percent I said do a custom one and put a percentage after it Uhm, so that's how that works Now note when 2:19 you're entering this now You enter it as a, not a decimal Uhm If it's 50% you enter 50 Uhm That's how it behaves and then you have to this agent commission calculation We're gonna have to divide it by a hundred and that'll get us the right number So let's check out this one Go to live app. 2:42 This is this new page with the different calculation and agent allocation Okay, so now we got it 40% 60% equals 100 one of the reasons My client wants this that we're dealing with when people are entering These commissions on a sale He wants it front and center that it equals 100 because it's supposed 3:06 to equal 100 every time So that works. That's a decent workaround. I'm going to mention a few things For my particular client, we have scattered throughout this app the regular percentage where they're putting 0.4, 0.6, and it turns into percentage And now for this particular one, for us, if he's insistent 3:25 on having the sum, we're going to have to put in integers. That's not a good user experience to have it different for different points. 3:31 Something's going to go wrong. And let me show you one other thing that they're going to have to work on too. 3:37 Sorry if I'm getting all over your neck. Watch this. Go to records. Let me make this bigger. Just watch this. 3:50 This is the one that's a regular percent, we're telling it to be a percent, 50. If I click on this, it gives me an opportunity to see what that is, .4, and I can edit it, I know, right there. 4:01 But watch the live app behavior. Let me make sure I got the right one. That's the first one. Now, when I inline edit here, I click it, it gives me a zero. 4:21 Because it, but in the back end, when you click it gives me the opportunity to see what it was. It's giving me a zero because it's rounding down. 4:31 You look at the six. Now, I could make it two decimals and tell it to give me two decimals. And that would solve that. 4:44 It's going to allow me to put that in just like we saw, but then it's going to give me two decimals. 4:48 I don't want two decimals. Uhm, it just looks, looks weird. I don't have to take a percentage out of two decimals for a commission rate. 4:56 So, there was the issue. There is a workaround that I just showed you. And here's a little static on the side. 5:06 Dealing with this percent stuff. That's what I got folks, thanks.