Date validation in a master/detail view

Hi everyone,
I have a problem and I hope someone can help me. I'm trying to create a validation for my application. I have a Master/Detail view where I add rows to my database and in the rows there is a "from date" and "to date". I want to create a validation so that the "from date" can not be chosen before the current date.
I'm having trouble because most of the tutorials I read on this work with page items, but since I have this in a Master/Detail view I have Column Attributes, wich do not behave the same way as page items.
Any help would be very appreciated.
Thanks,
Luka

I'm still having quite some trouble with this... everything I try gives me some sort of error.
My latest attempt was to make a PL/SQL returning boolean validation with the code:
FOR i IN 1..APEX_APPLICATION.G_F10.COUNT LOOP
IF DATUM_OD(APEX_APPLICATION.G_F10(i), 'DD.MM.YYYY HH24:MI') < SYSDATE THEN
return true;
else
return false;
END IF;
END LOOP;
and it says:
Error processing validation.
ORA-06550: line 2, column 4: PLS-00201: identifier 'DATUM_OD' must be declared ORA-06550: line 2, column 1: PL/SQL: Statement ignored

Similar Messages

  • 3 Levels Master Detail View Object with Java class interface

    Hi Developers,
    I've created 3 tables with one to many relations as below
    BOARD ------<- APPLICANT ------<- QUALIFICATION
    a board includes many applicants and an applicant includes many qualifications.
    When I add these tables to a Fusion Project, JDeveloper 11g helps me to add the Entity Links and View Associations automatically.
    Then, I defined these relations in an ApplicantModule's Data Model as below.
    [+] BoardVO1
          |
          |--[+] ApplicantVO1
                   |
                   |--[+] QualificationVO1The problem is: I cannot write any function in QualificationVO and publish it by client interface.
    I created a simple function with a single line (System.out.println(...) ) in QualificationVOImpl.java. and selected it in Client Interface. But when I execute it from the ApplicantionModel for testing, an oracle.jbo.NoObjException JBO-25003 is raised. with message: Object ... ApplicantVO1 of type ApplicationModule not found.
    Has anyone tried to implement some coding in the third level of a master details view structure as my example? How do you make it works?
    I'm using JDeveloper 11.1.1.3 with ADF BC.
    Regards,
    Samson Fu

    Samson,
    Looks like a bug (probably with the application module tester). I created your tables:
    create table board(board_id number primary key not null);
    create table applicant(applicant_id number primary key not null, board_id number not null);
    create table qualification(qualification_id number primary key not null, aplicant_id number not null);
    alter table applicant add a_fk foreign key(board_id) references board;
    alter table qualification add q_fk foreign key(aplicant_id) references applicant;I created a JDev project and got the same results. I've e-mailed a test case off to Frank.
    Frank - the method is indeed exposed on the VO instance, and I tried testing that way, but the AM tester gives the error as if it is looking for an AM instance with the VO's name.
    John

  • Performance Problem with Master-Detail Views

    Hi,
    I have developed a JSP-Applikcation with the master-detail views.
    I would like to report a bad performance at fetching data records from the detail view, because all records
    from master view have firstly to be retrieved to locate right row (rangesize="-1"). The number of records in
    the master table ist 2500 and 7000 in detail table.
    ============= Code Snippets (See HOWTO:Navigate using Data Tags of J. Oropeza) =====
    <jbo:DataSource id="dsMaster appid=testAppId viewobject="MaterView" rangesize="-1">
    <jbo:RefreshDataSource datasource="dsMaster">
    <jbo:Row id="msRow" datasource="dsMaster" action="Find" rowkeyparam="RowkeyValue">
    <jbo:dataSource id="dsDetail" appid="testAppId viewobject="DetailView">
    ======================================================================
    When rangesize="20" sets, performance is good, but the right row location of master view ist not found if the row
    is not positoned in this range (No data from detail view object are displayed).
    How can I improve the performance?
    Many thanks for your help.
    regards,
    Yoo

    Sung:
    Thank you for your suggestion.
    According to your suggestion I have changed my BC4J/JSP-application. However, the performance ist still bad.Whenn I click on a row retrieved from the master view, it takes 15 seconds until the associated data in detail view will be displayed on the other window (The application has been deployed on the test system of ISP).
    In an other case with much less data (162 master and 228 detail rows), it takes only 2 seconds (The application
    goes with the local server and DB of our company).
    ======================== master.jsp =================================
    <jbo:DataSource id="dsMaster appid=testAppId viewobject="MaterView" >
    <a href="detail.jsp?RowKeyValue=<jbo:ShowValue datasource="dsMaster" dataitem="RowKey"/>">
    Here Click
    </a>
    ======================== detail.jsp ======================================
    <jbo:DataSource id="dsMaster appid=testAppId viewobject="MaterView">
    <jbo:RefreshDataSource datasource="dsMaster">
    <jbo:Row id="msRow" datasource="dsMaster" action="Find" rowkeyparam="RowkeyValue">
    <jbo:dataSource id="dsDetail" appid="testAppId viewobject="DetailView">
    How do you think of this coding (My application is based on the document How to of J. Oropeza)?
    How can I increase the performance independently of the number of rows?
    Many thanks for your help.
    regards,
    Yoo

  • ADFBC JTree Master-Detail view

    Hello, I am using Jdeveloper 10.1.3.3. with ADFBC.
    I have table ORGUNIT with following fields:
    1. ID_ORGUNIT
    2. NAME
    3. ID_PARENT_ORGUNIT
    I have created Entity and View for this table, and ViewLink which is used for fields ID_ORGUNIT and ID_PARENT_ORGUNIT.
    In short, I am trying to create JTree which contains data about organizational units.
    Let's say these are my data:
    1. "ADM" "ADMINISTRATION" "NULL"
    2. "FIN" "FINANCING DEPARTMENT" "NULL"
    3. "FIN1" "FINANCING DEPARTMENT - XXX" "NULL"
    4. "FIN2" "FINANCING DEPARTMENT - YYY" "NULL"
    5. "DEV" "DEVELOPMENT DEPARTMENT" "NULL"
    So, I want to use JTree to create hierarchy:
    ADM
    I--FIN
    I I--FIN1
    I I--FIN2
    I
    I--DEV
    The problem is, when I create view link previously described...I get all data from view with their descendants...
    ADM
    I--FIN
    I I--FIN1
    I I--FIN2
    I
    I--DEV
    FIN
    I--FIN1
    I--FIN2
    FIN1
    FIN2
    DEV
    Can anyone help me? What could be the problem?

    Hi John,
    Thank you for your assistance.
    Just to confirm the details of what I have.
    Master VO: CustomerVO (based on customer table) correct!>Child VO: A VO based on a join between preferences and customer_preferences. (i.e. base your VO on two EO's) correct!what I have is a customer VO based on a customer EO, a customer_preferencesVO based on a customer_preferencesEO and a preferencesVO based on a preferencesEO.
    View links exist between customerVO and customer_preferencesVO and again between preferences and customer_preferences thus facilitating a many-to-many relationship.
    so what I'm trying to do is construct a master detail view between customers and preferences . I figured that in order to achieve this I would need to create two new VO instances, one for customers and one for preferences and then to probable use a statement in the where clause so that only preferences are returned for customers on the current row where a relationship exist via the customer_preverencesVO.
    This is where I'm struggling in understanding how best to implement this.
    All I want is a mechanism whereby when I come to use a tree view component in my UI model I will have a node that will display preferences.
    Thanks again,
    Gary

  • Can there be multiple Master Detail Views, if yes then how? Please suggest

    Dear All,
    In first master-detail view, I have a button, which when clicked will trigger the second detail view.
    I tried invoking second master detail view but was not able to see the second master view. Could you please guide as to how to go about this.
    Thanks.

    Do a Google search. Here's one link.
    http://mobiforge.com/developing/story/developing-split-view-based-apps-ipad
     Cheers, Tom

  • Problem occured when create a tree table for master-detail view objects using SQL queries?

    I am programming a tree table for master-detail view objects using SQL queries and these 2 view objects are not simple singel tables queries, and 2 complex SQL are prepared for master and view objects. see below:
    1. Master View object (key attribute is SourceBlock and some varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK,                   
            sum(                   
             case when cntr_list.cntr_size_q = '20'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr20 ,                   
            sum(                   
             case when cntr_list.cntr_size_q = '40'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr40 ,                   
             sum(                   
             case when cntr_list.cntr_size_q = '45'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr45                    
    FROM (       
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,       
               scn.CNTR_SIZE_Q,        
               count(scn.CNTR_SIZE_Q) AS cntr_qty        
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2       
        WHERE       
        scm.cmr_n = scn.cmr_n             
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                 
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                 
        AND scm.shift_mode_c = :ShiftModeCode                           
        AND scm.end_terminal_c = :TerminalCode      
        AND scm.start_terminal_c = yb1.terminal_c                  
        AND scm.start_block_n = yb1.block_n                  
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                  
        AND scm.end_terminal_c = yb2.terminal_c                  
        AND scm.end_block_n = yb2.block_n                  
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n           
        AND scn.status_c not in (1, 11)             
        AND scn.shift_type_c = 'V'             
        AND scn.source_c = 'S'       
        GROUP BY yb1.BLOCK_M, scn.CNTR_SIZE_Q       
    ) cntr_list       
    GROUP BY cntr_list.SOURCE_BLOCK
    2. Detail View object (key attributes are SourceBlock and EndBlock and same varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK,                
            sum(                     
             case when cntr_list.cntr_size_q = '20'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr20 ,                     
            sum(                     
             case when cntr_list.cntr_size_q = '40'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr40 ,                     
             sum(                     
             case when cntr_list.cntr_size_q = '45'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr45                      
    FROM (         
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,     
               yb2.BLOCK_M as END_BLOCK,  
               scn.CNTR_SIZE_Q,          
               count(scn.CNTR_SIZE_Q) AS cntr_qty          
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2         
        WHERE         
        scm.cmr_n = scn.cmr_n               
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                   
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                   
        AND scm.shift_mode_c = :ShiftModeCode                             
        AND scm.end_terminal_c = :TerminalCode        
        AND scm.start_terminal_c = yb1.terminal_c                    
        AND scm.start_block_n = yb1.block_n                    
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                    
        AND scm.end_terminal_c = yb2.terminal_c                    
        AND scm.end_block_n = yb2.block_n                    
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n             
        AND scn.status_c not in (1, 11)               
        AND scn.shift_type_c = 'V'               
        AND scn.source_c = 'S'         
        GROUP BY yb1.BLOCK_M, yb2.BLOCK_M, scn.CNTR_SIZE_Q         
    ) cntr_list         
    GROUP BY cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK
    3. I create a view link to create master-detail relationship for these 2 view objects.
    masterview.SourceBlock (1)->detailview.SourceBlock (*).
    4. I create a tree table using these 2 view objects with master-detail relationship.
    When I set default value for variable bindings of these 2 view objects and the matching records exist, tree table can work well. I can expand the master row to display detail row in UI.
    But I need to pass in dymamic parameter value for variable bindings of these 2 view objects, tree table cannnot work again. when I expand the master row and no detail row are displayed in UI.
    I am sure that I pass in correct parameter value for master/detail view objects and matching records exist.
    Managed Bean:
            DCIteratorBinding dc = (DCIteratorBinding)evaluteEL("#{bindings.MasterView1Iterator}");
            ViewObject vo = dc.getViewObject();
            System.out.println("Before MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            System.out.println("Before MasterView1Iterator ShiftModeCode="+ vo.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo.executeQuery();
            System.out.println("MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            DCIteratorBinding dc1 = (DCIteratorBinding)evaluteEL("#{bindings.DetailView1Iterator}");
            ViewObject vo1 = dc1.getViewObject();
            System.out.println("Before DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
            System.out.println("Before DetailView1Iterator ShiftModeCode="+ vo1.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo1.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo1.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo1.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo1.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo1.executeQuery();
            System.out.println("after DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
    5.  What's wrong in my implementation?  I don't have no problem to implement such a tree table if using simple master-detail tables view object, but now I have to use such 2 view objects using complex SQL for my requirement and variable bindings are necessary for detail view object although I also think a bit strange by myself.

    Hi Frank,
    Thank you and it can work.
    public void setLowHighSalaryRangeForDetailEmployeesAccessorViewObject(Number lowSalary,
                                                                              Number highSalary) {
            Row r = getCurrentRow();
            if (r != null) {
                RowSet rs = (RowSet)r.getAttribute("EmpView");
                if (rs != null) {
                    ViewObject accessorVO = rs.getViewObject();
                    accessorVO.setNamedWhereClauseParam("LowSalary", lowSalary);
                    accessorVO.setNamedWhereClauseParam("HighSalary", highSalary);
                executeQuery();
    but I have a quesiton in this way. in code snippet, it is first getting current row of current master VO to determine if update variables value of detail VO. in my case, current row is possibly null after executeQuery() of master VO and  I have to change current row manually like below.
    any idea?
                DCIteratorBinding dc = (DCIteratorBinding)ADFUtil.evaluateEL("#{bindings.SSForecastSourceBlockView1Iterator}");
                ViewObject vo = dc.getViewObject();           
                vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
                vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
                vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
                vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
                vo.executeQuery();
                vo.setCurrentRowAtRangeIndex(0);
                ((SSForecastSourceBlockViewImpl)vo).synchornizeAccessorVOVariableValues();

  • Master/Detail Viewer Application in Web Dynpro ABAP

    Hello @ll,
    i search a Master/Detail Viewer Application in Web Dynpro ABAP like this in WEB Dynpro Java (show below).
    http://help.sap.com/saphelp_nw04/helpdata/en/84/8bc1a36a38da41a46517b114ca0974/frameset.htm
    Have anyone a tutorial or can help how i config the event "onLeadSelect".
    I create a master- and detail table done all context mapping.
    Thanks in advance
    regards
    armin

    Hi Armin,
    Please go through
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/7a89b067-0801-0010-8192-a9896a60938e?quicklink=index&overridelayout=true
    Thanks,
    Prahsant

  • Foreign key validation while creating master/detail record in document mode

    I am creating master/detail records in the document mode. And I am generating the master primary key in the create() method of the master Entity Object. Now I valdate the foreign key in the detail Entity Object's validateEntity() method by doing a query to the master table through some View Object.
    But since the master record has not yet been posted (since it hasn't been committed) to the database, this query does not return any record and the validation fails in detail object.
    And thus the create fails.
    Please let me know if this is the right approach for doing this. If so where I am going wrong? Else please let me know if there are any better approach to do this.
    Kunal

    Kunal:
    Use a code snippet like the following:
    --- Assuming you're in the detail EO's create method ---
    oracle.jbo.server.EntityDefImpl eDef = oracle.jbo.server.EntityDefImpl.findDefObject(<package-qualified-name-of-the-master-Entity-Object>);
    oracle.jbo.Row masterRow = eDef.findByPrimaryKey(this.getDBTransaction(), <foreign-key>);
    If the row does not exist, masterRow will be null.
    findByPrimaryKey first checks the entity cache (which will include your new master row(s)) and then go out to database (if it's not in cache).
    Thanks.
    Sung

  • Insert a row in master detail view & jboRowKey parameter

    Hi
    I hava a minor problem.
    On JSP page I have edit form for master view, beyond edit form is browse of detail view. I would like to insert or edit a row on master view and after update and commit, a would like to stay on the same page to insert some rows into detail view.
    When I editing rows it is Ok, becose jboRowKey parameter is always the same (to find proper row on master view).
    Problem appears when I want to Insert a row into master view, becose after transaction is commited, jboRowKey parameter is changed.
    Primary key on master table is sequence and it is inserted by (preinsert) trigger before commit.
    If anybody has some idea to solve this problem, please help.
    Gorazd

    Without knowing exactly the technology you are using, (JDev version, BC4J JSP tags/Components tags?),
    In general with BC4J after you do a commit, you do not necessarily have a record pointer on the new record that you just insert on the master table, so you would have to locate it again.
    Here is one way you could do this.
    After you commit your new inserted record, you could go back to a master "browse" page which shows the records of your master table along with a link to it's corresponding detail page. Encoded in the link you could pass the rowkey of the master record as a parameter and then in the detail page you could locate the master record that was clicked on by using the Find operation of the Row tag. When the master row is located, you automatically would be pointing to the correct detail records.
    In this case since the master was just created, there wouldn't be any detail records yet. You could then create new detail records for the new master..
    Let me know if this helps..
    -Chris

  • ADF TreeTable One row data to create a master-detail parent-child relation

    I want to display an editable detail table on a page. The problem is the detail table has many fields so that the screen scrolls horizontally. I need my page to just fit on one page without scrolling.
    now my idea is to use a TreeTable. A lot of fields on the detail table will act as children of the main node so I can fit the table onto one screen without scrolling.
    So there is really no master detail relationship because Im referring to the same row data.
    Not the usual use case of using a Tree Table but just wondering if this is possible. I posted this hoping that anyone could shed a light on this.
    regards,
    Anton

    You can do that like in this example:
    http://apex.oracle.com/pls/apex/f?p=31517:278
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.apress.com/9781430235125
    http://apex.oracle.com/pls/apex/f?p=31517:1
    http://www.amazon.de/Oracle-APEX-XE-Praxis/dp/3826655494
    -------------------------------------------------------------------

  • Master detail view with drill down

    I am trying to develop a simple app for my Ipad. This app is supposed to have a Master/details look and should behave similar to the native Mail app (2x levels of navigation and the last level updates the details view).
    My problem is that I am not familiar to Apple IOS development so tend to get stuck all the time so I prefer to follow a tutorial or start with a sample project. I have searched for hours but I always either get a pure navigation drill down project without the details view or a pure master/details project with only a single level of navigation. I tried to take these projects and modify them but my knowledge sadly is very limited and I did not succeed.
    So can anybody direct me to a tutorial or a sample project where a Mail like app is being built with more than 1 level of navigation ?

    I have a GridBagLayout panel with a jtable and some jtextfield Well, we don't know exactly what constraints you have set up to its hard to say exactly why its happening.
    In general, you should create your JTextField using new JTextField(int) and I think the problem will go away.
    An easier solution would also be to use different LayoutManagers to achieve the desired layout.

  • Data block wizard breaks master-detail

    I've encountered the following situation, and I'm wondering if it's a known bug or if I'm doing something wrong:
    1. Open the data block wizard on an existing block that is the "detail" block of a master-detail relationship.
    2. Add one new field to the block. No other changes are made.
    3. When the form is recompiled and run, the master-detail relationship is broken. The detail block contains all the rows in the detail table. Clicking on the rows of the master block does not change the detail.
    Adding a field to the block manually does not cause a problem. The relation is not impacted, and we see no property settings that are wrong. We tried downloading and installing all of the latest patches for forms 6i, and the problem occurs with that release as well. Any ideas?

    I think you do something wrong because I add many fields many times and it works fine.
    Thanks
    Abubakr
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Steven Swartzlander:
    I've encountered the following situation, and I'm wondering if it's a known bug or if I'm doing something wrong:
    1. Open the data block wizard on an existing block that is the "detail" block of a master-detail relationship.
    2. Add one new field to the block. No other changes are made.
    3. When the form is recompiled and run, the master-detail relationship is broken. The detail block contains all the rows in the detail table. Clicking on the rows of the master block does not change the detail.
    Adding a field to the block manually does not cause a problem. The relation is not impacted, and we see no property settings that are wrong. We tried downloading and installing all of the latest patches for forms 6i, and the problem occurs with that release as well. Any ideas?<HR></BLOCKQUOTE>
    null

  • Download data as excel from master-detail form.

    Hi All,
    I have created master-detail form with two tables(i.e orders and items). how can i import data of specific order into excel using single button click. Can any one help me.
    I am using apex 4.1 version
    Regards,
    Vijay. J

    I have created master detail form. when i click on the button then the would downloaded to excel like below format. when we open the order and click the download button it fetch the line items of that order and display in below format (This like normal invoice form).
    CompanyName
    Bill to Address Shift to address
    Item code qty item price
    1 1 2000
    2 1 3000
    total 50000
    -------------------------------------------------------------------------------------------

  • Validating WEBDB2.2 Master-Detail form

    I would like to validate a Master-Detail form using Javascript in WEBDB 2.2. There is the option to validate field/forms in other types of Forms (based on Table/View, based on Query, etc...) but I do not see that option in a Master-Detail Form. Any help would be appreciated.
    Thanks

    If you are on a Portal Version lesser than 3.0.9.8.3, then please try the following to populate
    the PART_DESCRIPTION field.
    Steps:-
    1> Edit the form and go to the Additional PL/SQl section and put the following code in the
    "...after displaying the page area" :-
    declare
    type t_vc_arr is table of varchar2(4000) index by binary_integer;
    l_arr_desc t_vc_arr;
    l_form_name varchar2(200);
    l_form_state varchar2(500);
    begin
    l_form_name := p_session.get_module().get_name();
    l_form_state := p_session.get_value_as_varchar2(
    p_block_name => 'MASTER_BLOCK',
    p_attribute_name => '_FORM_STATE'
    if l_form_state = 'QUERY_AND_SAVE' then
    select description
    bulk collect into l_arr_desc
    from <schema>.table_x;
    htp.p('
    <script>
    var descArr = new Array();
    var Fidx = 1;
    var formObj = document.WWVM'||p_session.get_id()||';
    var fieldName = "'||l_form_name||'.DETAIL_BLOCK.PART_DESCRIPTION.0";
    for i in 1..l_arr_desc.count loop
    htp.p('descArr['||to_char(i-1)||']="'||l_arr_desc(i)||'";');
    end loop;
    htp.p('
    for (var i=0; i < formObj.length; i++){
    if (formObj.elements.name == fieldName+Fidx){
    formObj.elements[i].value = descArr[Fidx-1];
    ++Fidx;
    htp.p('</script>');
    end if;
    end;

  • ADF Faces and multiframe window for master/detail view

    Hi,
    I have a web page divide into 2 frames : frame1, the master view and frame2 the detail view.
    When I load the whole web page, the master frame print all the paginated list. Each row has a "show more" button. When I click one, the corresponding detail view is displayed in the detail view (frame2). And, when I clicked again the "show more" button, the paginated list (present in the master view) is displayed in the detail view !!! WHY ??
    When I click a third time on the "show more" button, the detail view display the corresponding detail information (work well like first click)....and alternatively clicking on the "show more" button, this problems occurs.
    Where does this problem come from ?
    The ADF Faces code shown in the master view (targetFrame attribute means to display on the detail view when show more button is clicked).
    <?xml version="1.0" encoding="iso-8859-1"?>
    <!-- table displaying the list of buildings -->
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="1.2"
         xmlns:f="http://java.sun.com/jsf/core"
         xmlns:h="http://java.sun.com/jsf/html"
         xmlns:afh="http://xmlns.oracle.com/adf/faces/html"
         xmlns:af="http://xmlns.oracle.com/adf/faces">
         <jsp:directive.page contentType="text/html;charset=utf-8" />
         <f:view >
              <af:document title="List of buildings" >
                   <af:form >
                        <af:panelPage title="Show the list of buildings">
                             <af:table var="building" value="#{buildingsBean.buildingsList}">
                                  <af:column>
                                       <af:outputText value="#{building.name}" />
                                  </af:column>
                                  <af:column>
                                       <af:outputText value="#{building.objectId}" />
                                  </af:column>
                                  <af:column>
                                       <af:commandButton text="Show more"
                                            action="#{adfMasterSlaveBackingBean.showBuilding}" >
                                       </af:commandButton>
                                  </af:column>
                             </af:table>
                        </af:panelPage>
                   </af:form>
              </af:document>
         </f:view>
    </jsp:root>

    Yes I put a targetFrame (I forgot to restablish it).
    Code of the backing bean (to show building list) :
    public List getBuildingsList() throws Exception {
              System.out.println("getBuildings");          
              CLPNetworkInstanceAPI netAPI = CLPNetworkInstanceAPI.getNetworkInstanceAPI();
              buildingsList.clear();
    try {
         CTResource resources[] = netAPI.fetchAllResourcesByType("CLPRMBuilding");      
                   for (int i=0; i<resources.length;i++)
                        buildingsList.add(resources);
              } catch (CTConnectionException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              } catch (CTUnsupportedTypeException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              return buildingsList;
    and the backing bean to show building detail :
    public String showBuilding() {
              FacesContext context = FacesContext.getCurrentInstance();
              CLPRMBuilding building = (CLPRMBuilding)
         context.getApplication().getVariableResolver().resolveVariable(context, "building");
         if (building == null)
         return "error";
         AdfFacesContext afContext = AdfFacesContext.getCurrentInstance();
         afContext.getProcessScope().put("buildingDetail", building);
         return "showBuilding";

Maybe you are looking for

  • Mail attachment: difference between script and app bundle?

    Hiya Folks, I am trying to make an application in Applescript that will receive a file, then create a new email (in Mail.app) with that file attached. I would prefer it to be an app, rather than a script when it's finished. I have a script that appea

  • I tunes will not open with Window XP

    I have try everything that is on the site and can't get Itunes to work on my windows pc. That is the new version. No problem on my power book Mac. I use itunes on my windows pc and everything worked fine until the new version came out. I know that ap

  • Adobe Premiere Elements 10  install disk missing

      Adobe Premiere Elements 10 Win bought/register  it on July 16, 2012 and now i miss disk 2(64bit install disk ) ,is there a other way of installing it greetz morris langeveld

  • Unable to open Macro file in Excel 2013 but opens fine in Excel 2010

    Hello, Hopefully someone can help us.  We have a Macro Excel file created with Password Protected to open as well as to Modify.  The file opens fine in version 2010. However, in Excel 2013, we get an error message "Cannot run the macro "filename.xlsm

  • Encoding error occurs using parameter "default path for scripts"

    Hello, assume we have a script "/home/artur/tymczasowe/test.sql". I can execute it using SQL Developer by: @/home/artur/tymczasowe/test.sql Everything works as expected. Then I set parameter "Tools - Preferences - Database - Worksheet - Default path