Solved

Calculate Sum of Field and populate list error

Posted on 2004-03-22
2
744 Views
Last Modified: 2013-12-12
hi!
    I have a tabular foRm having a fields TASK, UPL_STT, SK, INVOICE_NUM and QTY..name of my block is UP_F.. I created LIST ITEMS named LB_STAT_LIST (to filter UPL_STT), LB_INV_LIST (to filter INVOICE_NUM) and LB_SKU_LIST (to filter SKU's only)...now what i want to do is i want to get the sum of QTY when I choose specific SKU IN LB_SKU_LIST...how will i do this in run time...i have checked the help and i can't get it...could you give me steps or example?

and another thing...

I am dynamically inserting values from the DB
into a Oracle forms list item.

Its working when the data type of the list item is set to char. But when I change it to a Date datatype or a Number datatype to suit the column fields accordingly, I am getting this error :

FRM-41335 : Populate_List : invalid column type
for column 1.



Regards
0
Comment
Question by:GoodHands_Delphi
2 Comments
 
LVL 22

Expert Comment

by:Helena Marková
Comment Utility
"and another thing..."
FRM-41335:
This is from the on-line helpp "POPULATE_LIST built-in"
Removes the contents of the current list and populates the list with the values from a record group. The record group must be created at runtime and it must have the following two column (VARCHAR2) structure:
Column 1:      Column 2:
the list label      the list value

so as you can see the column type must be VARCHAR2.

For your first question - use When-List-Changed Trigger:
Fires when an end user selects a different element in a list item or de-selects the currently selected element.  In addition, if a When-List-Changed trigger is attached to a combo box style list item, it fires each time the end user enters or modifies entered text.
0
 
LVL 6

Accepted Solution

by:
musdu earned 20 total points
Comment Utility
Hi,

to get sum of QTY field, create a new numeric field in the same block and set the property of "Number Of Items Displayed" to 1 (this will create a single occurrence item). Then set the "Calculation Mode" property to "summary" and set "Summary Function" to "sum" and "Summarized Block" to "UP_F" and set "Summarized Item" property to "QTY" and this is last one :) set the "Query All Records" property of block UP_F to "YES". When you execute a query on your block, your field will be filled with sum of QTY field.

regards.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Working with Network Access Control Lists in Oracle 11g (part 2) Part 1: http://www.e-e.com/A_8429.html Previously, I introduced the basics of network ACL's including how to create, delete and modify entries to allow and deny access.  For many…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now