Forms :: How To Populate Combo Box Dynamically Based On Another Combo Box
Aug 25, 2006
I have a combo box,If I select a value from this combo box it should populate another Combo box automatically.
Example:-
state
sno cno statename
1 1 newyork
2 1 boston
3 1 florida
1 2 brisbane
2 2 sydney
country
cno country name
1 usa
2 Aus
if i select usa in first combo box in next combo box i have to populate only states that belong to that country.
BY example above:
If in first combo box i select AUS
then in next combo box i.e., in
second combo== brisbane
sydney only must be there .
i need the exact code with trigger.
View 4 Replies
ADVERTISEMENT
Feb 17, 2010
I have created one form using oracle ids. i want add value into combo box in runtime.
View 3 Replies
View Related
Feb 12, 2010
i want to get user (dba roles in combo box runt time).i have write down this code in when new form instance.
declare
rg_id recordgroup := find_group('RG') ;
ln_error number ;
begin
if not id_null(rg_id) then
ln_error := populate_group(rg_id) ;
if ln_error = 0 then
populate_list('BLOCK3.T' , rg_id) ;
else
message('Error in Populating Group') ;
end if ;
end if ;
end ;
attached file.when i run it gives the follwoing error. frm-41334-invalid record group.
record group query is: SELECT GRANTED_ROLE FROM DBA_ROLE_PRIVS WHERE GRANTEE='MTSYS'
View 6 Replies
View Related
Mar 26, 2010
I want to populate a combo box using values from a table, I know you can manually enter values in the combo box's property palette using the 'Elements in List' option, but this combo box will have changing values and I would prefer it to come from a table rather than manual entry so that when users add a new staff name to the table it will automatically be in the combo box.
I would need to use a trigger on this combo box, but which is the best to use and im guessing the SQL needed is more than just 'select * from staffname'?
View 6 Replies
View Related
Dec 30, 2010
I have a list box that is populated from a record group using a WHEN-NEW-FORM trigger. When I run the form this displays fine when the list box is set as Poplist or Tlist, but when I change this to combo box and run the form it doesn't load properly in the browser (a blank screen followed by the background a a toolbar that says window).
View 3 Replies
View Related
Mar 15, 2013
i want to create the list item dynamically on the when new form instance this is the code....
group_id := create_group_from_query('lst','select (imt.item_id), to_char(imt.item_code, from items_mt imt');
v_num := Populate_group(group_id);
populate_list(v_num,group_id);
but the list is not the populate.
View 14 Replies
View Related
Mar 3, 2011
I've got a situation where I need to populate a list box of lab numbers when the user selects a matching date received date.
Right now it only works when the user presses enter on the field used to accept a date.
It also works when a user fills in date and then clicks twice on the listbox of lab numbers. (assuming there are some records for the date in question).
Both fields are in a data block that is not connected to a table. Here is the when-mouse-doubleclicked trigger
LAUNCH_CALENDAR('DISPLAY.DATE_BEAN');
IF :DISPLAY.DATE_RECEIVED IS NOT NULL THEN
GO_ITEM('display.list_labno');
--POPULATE_LIST_ITEMS('date_received_records','display.list_labno');
do_key('list_values');
[Code]....
As you can see we have tried several different triggers to get this to work with a calendar date chooser (java bean). The bean works and allows for a date to be returned. However, it does not want to populate the listbox.
View 5 Replies
View Related
May 14, 2010
I'am having a query regarding population of a list item based on another selected list item that is whenever i select the state from the combo box all the city's under that state should be automatically populated.
View 4 Replies
View Related
May 29, 2011
I have two blocks.In header 2 columns are there same columns in line how to populate default values in line level based on header?
View 1 Replies
View Related
Apr 24, 2013
I would like to populate a text box based on selection from a LOV. If someone selects a LOV value and then tabs off off of that element, I would like the text box populated from a sql statement based on the LOV value in the predicate.Application Express 4.1.1.00.23
View 1 Replies
View Related
Dec 27, 2012
Ive a requirement which ive overlooked for a while now as below,
On my tabular form i have fields: Empid as Select List and when the value is picked from this Select List EmpID i want the associated/corresponding phone# displayed in its TEXT FIELD in that same row,
apex 4.1.1/Oracle 11gR2,
also i tried the below as a workaround but it doesnt fulfill my requirement, [URL]....
View 1 Replies
View Related
May 10, 2013
I am new to PL/SQL, worked mostly on SQL server, I have to change the table name dynamically based on the parameter.and used a ref_cursor to display the results in a report. when I execute it throws me an error.
create or replace procedure test1 (
p_eod_date IN VARCHAR2,
p_link IN NUMBER,
c_rec IN OUT SYS_REFCURSOR)
[code]....
View 10 Replies
View Related
Jul 14, 2011
I have following requirement. Let say i have to generate a range based on "start number" and "end number" dynamically.Some kind of hash buckets.
e.g Start Number : 1 and End Number : 1001.
Also i want to divide that range based on some dynamic value like for above example 10 ranges of 100 each. and both 1 and 1001 should be included only once and the next row start number cannot be same as previous row end number.
Means
Range 1 1 -101
Range 2 102-200
Range 3 201-300
...
Range 10 901-1001
Is there any way of doing it automatically. I tried with Model clause. it works fine for even cases but for odd i have issues also when i take small start and end number i get an error.
SELECT case when ranges=1 then ranges else ranges+1 end Start_Id, ranges+round((1001-1)/10) End_Id
from
(
[Code].....
I want this to be generic for any values here 1 is Start Number 1001 is end number and 10 is the bucket. I need these parameters dynamic and want's the same kind of results for any values.
View 22 Replies
View Related
Feb 17, 2011
My requirement is to concatenate two column values and place them in a new column.I have done it using self join but it limits the purpose,meaning when I have more than 2 values for grouped columns then it won't work.How to make this dynamic,so that for any number of columns grouped,I can concatenate.
SELECT a.co_nm, a.mnfst_nr, a.mnfst_qty,
a.mnfst_nr || ':' || a.mnfst_qty || ';' || b.mnfst_nr || ':'
|| b.mnfst_qty
FROM vw_acao_critical a JOIN vw_acao_critical b
ON a.co_nm = b.co_nm AND a.mnfst_nr = b.mnfst_nr
[code]......
What will be the case when I need to concatenate for more number of values.
like when co_nm has three bahs and manfst_nr and manfst_qty has 3 values for each for bah.and if three are having same_mnfst nr then I should use something dynamic.how to achieve this.
View 10 Replies
View Related
Nov 29, 2012
below requirement..
We have certain records like SQL, PL/SQL, Reports, Forms, OAF etc in a table. We wanted to capture rating for each of these criteria. So we want a form to be displayed dynamically..
SQL 1 2 3 4 (1,2,3,4 represent radio buttons)
PL/SQL 1 2 3 4
Reports 1 2 3 4
Forms 1 2 3 4
OAF 1 2 3 4
If we add another row, XMLP in that table additional radio button should be displayed automatically..
View 4 Replies
View Related
Mar 2, 2011
Create a form based on the following output use EMP Table
Create a non Database Block i.e Control Block----> Dept No
Create a Database Block -EMP
Create an LOV for the Dept no from dept table.
For the Current Dept No . Populate the Employee Records
View 3 Replies
View Related
Apr 4, 2011
-- Solution populate poplist
----------------------------
-- Name of block: block01
-- Name of poplist item: year
-- Name table: tb_years
-- Create on trigger when-new-form-instance
[code]...
View 3 Replies
View Related
Oct 14, 2010
.fmb file why this populate lov is not working
View 9 Replies
View Related
Apr 1, 2013
I want to populate only particular employee LOV ,when i am press "Populate LOV"..Button and i attached Form for testing and It is a 10g version..
View 5 Replies
View Related
Dec 3, 2010
TABLE_FROM_BLOCK built-in Package is working in Forms 6i but not in Forms 10g. is there any other built -in available instead of this. how do we populate table from a block in Forms 10g?
View 6 Replies
View Related
Aug 14, 2013
i have created on query block , upon pressing the button there is a wehre clause in the block which will filter the records based on all alike items from two tables but my problem is , in one table there is no information of struct and in other there is struct information or data, what i want is even if i pass a parameter in the where clause all the records should be filtered.
CREATE TABLE OT_ACTUAL_ACT (ITEM_CODE VARCHAR2(30),ITEM_NAME VARCHAR2(30),WO VARCHAR2(12),STRUCT VARCHAR2(12))
INSERT INTO OT_ACTUAL_ACT(ITEM_CODE,ITEM_NAME,WO,STRUCT)
VALUES ('1001','HEA100X10','300',null);
[Code]...
I am getting this
ITEM_CODEITEM_NAMEWOSTRUCT
1002 HEA100X2230030010
i want all the records
ITEM_CODEITEM_NAMEWOSTRUCT
1002 HEA100X2230030010
1003 HEA100 300
1001 HEA100X10 300
View 1 Replies
View Related
Jul 14, 2010
My Requirements:
1. i want to create form for student's attendance.
2. for this purpose i create a form . and create 2 Data Blocks
1. Non Database Data Block (layout type: form)
2. Database Data Block (layout type: Tabular)
3. in Non Database Data Block i add 3 Items.. on the basis of i get the records from database and show them into my into my 2nd Data Block...
4. my problem is this that how can i get records from database and show them into my forms and then save thats records into my table by using Database Datablock.
View 2 Replies
View Related
May 3, 2011
i have two blocks called BLOCK1 AND BLOCK2
BLOCK1 is a multi record block with a field, FIELD_A
BLOCK2 is a multi record block with fields FIELD_B,FIELD_C,FIELD_D
i have a button on BLOCK1 called 'FETCH'.
The requirement is when_button_pressed on 'FETCH'. BLOCK2 must be populated for each record of BLOCK1. Population logic is based on, values from a database table TABLE_A which has got column values corresponding to all fields of BLOCK1 and BLOCK2.
View 7 Replies
View Related
Aug 6, 2010
i want to popultate record in list item.... and write the follwing code...
PROCEDURE POPULATE_REC_IN_COMBO_BOX IS
RG_NAME VARCHAR2(500) :='RGGROUP';
RG_ID RECORDGROUP;
ERRCODE NUMBER;
BEGIN
[code].....
when i call this code then it returns the 2 errors:
1. FRM-41072: Cannot create Group RGGROUP.
2. FRM-41076: Error populating Group.
View 16 Replies
View Related
Jun 26, 2013
how should i populate table column heading in list items of forms? I've create lov to select the column, then i have 10 separate list items. once i select the table from lov then list item should get populated with selected table column.
View 2 Replies
View Related
Mar 14, 2013
On a form I have 2 blocks, shown on different tabs. Relation created by forms wizard. The relation works great when navigating through the blocks, the details for the master are shown fine.
Example for this form is master block is a type of food. Detail block is list of ingredients.When creating a new type of food, if it's = CAKE we insert records based on a select on another table into the ingredients table.Else, the user has to manually create the ingredients.
Upon commit of the form on master block (must be saved to enable detail block tab), the ingredients are not displayed but are there. If I execute query by hitting F8, the records are present.
Why is the populate-details trigger not being fired or what am I missing?
View 4 Replies
View Related
Jun 17, 2013
In alters I want to display a value dynamically.
like when deptno=10 came then it should dynamically displays the message like Department 10''.
when deptno=20 came then it should dynamically displays the message like Department 20''. and.....
View 4 Replies
View Related
Jul 20, 2010
i have list item populated with many table names from a schema. i have grid in oracle forms 10g and i want to fill the grid with at least four/more columns.I want to fire the list change trigger when each time any one table name is selected.
how can i find the columns names dynamically for filling the grid.
View 6 Replies
View Related
Jul 4, 2011
I am working on 6i reports.I have below scenario to achieve.
I have FIND window and MAIN Window.
FIND Window: contains EMPNO, ENAME,and FIND button.
MAIN WINDOW: EMPNO, ENAME, SAL, JOB
If i enter something in FIND window, by clicking FIND button, it will populate data in MAIN window.I have below query in WHEN BUTTON PRESSED TRIGGER.
declare
cursor c1 is select empno, ename, job, sal from emp
where empno=nvl(:FIND.empno,empno)
and ename=nvl(:FIND.ename,ename)
begin
--here i am populating data into MAIN window block
end;
It's working fine.
REQUIREMENT: i want to pass where statement dynamically. Let us say if i pass only empno in FIND window, i want to pass 'WHERE empno=:FIND.empno' to existing select statement [I will keep select statement same without where condition]
If i pass empno and ename both, i want to pass 'WHERE empno=:FIND.empno and ename=:FIND.ename.
How to pass where condition to existing select statement based on parameters we pass in FIND window.
View 8 Replies
View Related
Aug 5, 2013
I am trying a pl/sql block which which take a string and execute it dynamically. Suppose below is string
M_COL := Q'[(P_CODE=> ':DEPTNO',P_CODE_TYPE => 'STATE')]';
Now trying to execute it. using below
M_STR := 'SELECT CHK_DEPT' || M_COL || ' FROM EMP WHERE EMPNO=''7499''';
EXECUTE IMMEDIATE M_STR
INTO M_DATE;
Now what i want is M_STR vairable to executed as
SELECT CHK_DEPT(P_CODE=> DEPTNO,P_CODE_TYPE => 'STATE') FROM EMP WHERE EMPNO='7499'
instead of
SELECT CHK_DEPT(P_CODE=> 'DEPTNO',P_CODE_TYPE => 'STATE') FROM EMP WHERE EMPNO='7499'
other in other way in parameter P_CODE Column value of DEPTNO should be passed.Also note that DEPTNO column in string M_COL is Dynamic.i.e
M_COL := Q'[(P_CODE=> ':DEPTID',P_CODE_TYPE => 'STATE')]'; OR
M_COL := Q'[(P_CODE=> ':EMP_ID',P_CODE_TYPE => 'STATE')]';
View 9 Replies
View Related