How to Add Items prices for a Total

So I’m trying to add my Items prices and input them into a Total, I can make it where the User has to manually do that but that’s very last resort I was hoping someone can help me out with the work flow to get the prices to add and get input to the total section and should my total be a repeating group text or is it fine in just the input the way it is? Any help would be appreciated.

It will cost you, but check out the bdk repeating group plugin. It was basically made for this. It made my life very very easy.

I would like to do this without buying plugins, as I do not have the money to spend otherwise I would have got it a long time ago lol

You can just use RG list of items:sum

Okay so it does need a RG Table?

The items in the pictures are not from a RG?

Answers to this question are pretty heavily dependent on how you’ve structured your data, but @Jici already pretty much answered your question - there is literally a “sum” function for a list of numbers, so that is what you would use.

1 Like

Heres what is RG and not RG for that part

So just replace the “total” test by
Repeating Group’s list of items amount:sum (click on more to see the :sum after selecting the amount field)

I’ve never seem the Sum function I’ve never needed it, but its more or less making sure I have it setup correctly if the Total needs to have a RG or not

Okay thank you I will do that right now

This is not the Total itself that is the RG. But the data you use for the sum come from the RG.

I’m confused sorry, I’ve always been bad at understanding stuff like this

1 Like

Its not working maybe its because I’m Using Rate * Quantity in the RG Amount?

In this case you cannot do it directly (I think that the BDK plugin can).
But… if you review how your DB work, yes you can without the plugin.

You should have a “Carts” things linked to the invoice.
In this cart you will have a “total” number field, a quantity field and an “item” linked to the item DB.
When user add item, you will Set Quantity field, Item field and total will be Quantity* Item’s price

The RG will be set on the Carts thing. The left column will use Current cell carts item’s name. On the second line you will have Currents cell cats item’s price * Currents cell carts quantity. On the right column you will use Current cell Carts total

In total, this will be RG list of carts’ total:sum

Maybe if you share you app in edit mode we can understand a little bit more DB setting and help you

I changed it to view I think I misunderstood you I also have my database setup only as prototype so the fields change from Text to Number or what ever I need them to when I get to that point

So actually, there’s a lot of thing to review in your DB. Your are not using any link between DB.
I think you should have
Invoice -> Invoice Items (what I called Carts) -> Items

The invoice is the main container and can contain a full total of all items*qty. Invoice items is where quantity and each item total will be calculated. Finally, Item are the unique element where the price for this item should be (with description, pictures…)

I’m not understanding what you mean to be honest, so I’ll try my best to say what I think you mean
So in Invoice database take out Item Description and Item Rate, then in Invoice items take out every thing except Quantity and Item Total and then in Items take out Quantity?

Sorry I’ve always been bad at written directions like that

In invoice DB, add a field that will point (field type) to Invoice Items (list). In Invoice Items, Add a field that will point to “Item”. Start from there.