Help Needed for Freight Calculation [message #681806] |
Tue, 01 September 2020 08:50 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](//www.gravatar.com/avatar/21360a3df5a575e8b0e13c248c7869c3?s=64&d=mm&r=g) |
M HANIF
Messages: 20 Registered: April 2019
|
Junior Member |
|
|
Assalam-o-Alaikum!
Dear experts.... I am new in learning Oracle..
I need some help to calculate and add freight charges in purchased products..
please help me...
I purchased 2 products as 5 kg and 10 kg..
rates 100 and 200...
freight charges on both combine are 300 rupees...
What will be the formula to calculate appropriate freight charges of each product according to their purchased price?
I have another software where when I add these products for test
for 1 product it calculates freight and cost is 160
When I add second product the cost changes to 112 and 224 for both products..
I am uploading screen shot for clearly understanding...
See and help me....
Thanks
Muhammad Hanif
|
|
|
|
|
|
Re: Help Needed for Freight Calculation [message #681834 is a reply to message #681829] |
Thu, 03 September 2020 01:22 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
![](//www.gravatar.com/avatar/21360a3df5a575e8b0e13c248c7869c3?s=64&d=mm&r=g) |
M HANIF
Messages: 20 Registered: April 2019
|
Junior Member |
|
|
Littlefoot wrote on Wed, 02 September 2020 15:18Quote:the problem is that the field where I use formula cannot enter value into database
Why not? Is that field based on a table column (and the block based on the table)? If so, it *should* work simply by committing changes you've made.
Otherwise, it depends on what the form actually does, what it is based on, and what processing you do. Perhaps you'll have to store that value manually (e.g. by creating a PRE-INSERT trigger, or write an ON-INSERT trigger), or call a procedure which will do that for you, or ...
Dear Brother,
Block is also a database block, based on table, field is also database item and column name is also based on table column name....
But on any database item, when calculation mode is changed to formula and formula is inserted....it does not store values into database table....
I'm confused.....
If I create a function then,
from where it will be called?
Or the trigger Pre-Insert/ Post-Insert.....will it be a block level trigger?
|
|
|