edlentz
Posts: 11
|
Posted: 03/02/2004, 4:28 AM |
|
I desperately need to do some simple math and have hit a wall in figuring this out. I have grids that show products that have been sold. the grids have qty, price, ext price, and tax fields. How do I do the math. ie: qty*price = ext total then extTotal*.06 for tax. I am using CCS/php and I need this to start billing customer.
Can someone help?
Thanks
Ed Lentz
|
|
|
peterr
Posts: 5971
|
Posted: 03/02/2004, 4:34 AM |
|
What would you like to do with these calculations? For example how would you use the extTotal or tax?
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
|
|
edlentz
Posts: 11
|
Posted: 03/02/2004, 5:13 AM |
|
Sorry I guess I wasn't to specific. I have a page with a grid with qty,price,tax, extotal. I need it to do the math and then enter it into the record of my mysql table, so I would need a update statement. I then need to make a grid on another page that will contain all these fieilds and run a total of tax, and parts. I am making a service database system and the math is getting to me.
I hope this is more clear
Thanks
Ed
|
|
|
peterr
Posts: 5971
|
Posted: 03/02/2004, 11:20 PM |
|
Sorry but I still have hard time figuring out what you're doing. Let's say that a grid is displaying the data - do you want to update your database as soon as the page with the grid is being displayed?
Or is it the Ediatable Grid? If so, then our example "Master-Detail Form for Order Entry" in CCS Example Pack shows a similar situation, there is a Unit Price and Quantity, but the Extended Price is automatically calculated. You can also make such field(s) hidden so that users don't see it.
There is no need for "update statement" because the grid data is submitted by users and updated automatically.
An example of displaying the total for a grid is in the documentation ("Simple Report with Total").
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
|
|
edlentz
Posts: 11
|
Posted: 03/03/2004, 5:47 AM |
|
Thanks Peterr Those suggestions might work. I will give them some attention.
Ed Lentz
|
|
|
|