Transient attribute based on the selected query by using a function call

Hello

Post version is 11.1.1.7.0 JDeveloper.

I'm not able to get the following work properly;

  1. I have a scenario header / detail.
  2. Calculate a value for each row returned detail that I find. This calculation is done using an existing database to function.
  3. The function requires 3 input parameters.
  4. Two of these parameters can be retrieved in the detail row and one is a value which is on the header.
  5. I created a transient attribute on the object of the detail view and selected the following properties of the 2 attribute;
    1. Mapped to the column or SQL
    2. Selected in SQL
  6. I entered the following SQL Expression;
    1. function_name (DetailTableAlias.value1, DetailTableAlias.value2, ViewLinkName.value3)
  7. Running AOS that contains the objects of view header / detail, I encounter a SQL error which indicates that ViewLinkName.value3 is an invalid identifier.
    1. I can understand why this error occurs.
  8. If I change the ViewLinkName.value3 to a literal value, the error will not occur.

So, my question is how can I pass the third parameter to the transitional attribute database function call as the value literal and not as a reference to one, missing attachments header table, column?

Concerning

Leon.

Hi Leon

Have you explored solve this by an inline SQL query to derive the 3rd parameter of the function? In other words, the problem in SQL instead of ADF.

DMI

Tags: Java

Similar Questions

  • passing parameters to the select query in DB link to call him...

    I have a DB link that executes the select query based on user specified parameter.

    Now, I created an invoke activity and specified input [which must be passed to the query] and output parameters [it is the result of the query]. That invoke link activity DB calls in which a parameter was created to be used in the select query. So my question is, DB link partner take the input parameter of call activity automatically or do we need to specify a mapping for this?

    When you create a partnerlink db the setting that you create for your chosen matches the entry and when you create the variable entry in the invoke for this partnerlink is created with the type of the parameter.

    Create an assignment before your invoke and assign a value to the input variable that you created in the invoke. This value will be passed and used as a parameter in the selection.

    Heidi.

  • The select query-based search page...

    I want to create a basic search page at the base on a select query.

    The select query will not be based on Table.Its based on functions.

    I created a view like this object

    Select xx_test_accruals(:p_date) of ACCUMULATION: p_date double DT

    I created a search page

    In the area of provision of Home Page, I added a region of the query. In this region of request I created a result based research Table.

    When I run the page opens with the field

    DT

    When I get back the date and click go, I get the error message like this...

    oracle.apps.fnd.framework.OAException: oracle.jbo.SQLStmtException: 27122 Houston: SQL error in the preparation of the statement. Statement: SELECT * FROM (select xx_test_accruals(:p_date) of ACCUMULATION: p_date double DT) QRSLT WHERE ((UPPER (DT) like: 1 AND (DT as: 2 OR DT as: 3 OR DT as: 4 OR DT as: 5)))



    Help, please

    Published by: [email protected] on October 4, 2009 14:04

    Hello

    I tried it on my machine... There is a little change on the approach.

    See we have a display object: XxAccrualsSummaryVO

    the query is

    Select xx_test_accruals (to_date (: 1, 'YYYY-MM-DD')) DT ACCRUAL, double to_date(:2,'YYYY-MM-DD')

    Create a view property object: say DateTestPVO and create a transitional DATE type attribute say dated. MinValue. How to create the View Object(read in dev guide) property.

    Link the date to DateTestPVO text entry and the date attribute. MinValue.

    Now that the page will load in process request initialize the PVO not XxAccrualsSummaryVO.

    Public Sub initialisePVO()
    {

    OAViewObject vo = (OAViewObject) getDatePVO1 ();
    If (! vo.isPreparedForExecution ())
    {
    vo.setMaxFetchSize (0);
    }
    Line = vo.createRow ();
    vo.insertRow (row);
    row.setNewRowState (Row.STATUS_INITIALIZED);

    }

    And when you press the Go button and then enter the date entered and set the location where the XxAccrualsSummaryVO clause.

    If (PageContext.GetParameter ("Go")! = null)
    {
    Get the value entered by the user in the date field.

    DateField OAMessageDateFieldBean = (OAMessageDateFieldBean) webBean.findIndexedChildRecursive ("text");
    String datetest = (String) dateField.getValue (pageContext) m:System.NET.SocketAddress.ToString ();
    Now set the where clause VO settings.
    OAViewObject vodate = (OAViewObject) am.findViewObject ("invoicetestVO1");
    vodate.setWhereClauseParams (null);
    vodate.setWhereClauseParam(0,datetest);
    vodate.setWhereClauseParam(1,datetest);
    vodate.executeQuery ();
    }

    It works perfectly... I tested it.

    Thank you
    Gerard

  • Auto-fill text box values field based on the selection of the menu drop-down

    Try to fill in address, city, province, zip from text fields based on the selected option in a select form field. The following code works fine in Internet Explorer, but in Chrome or Firefox, after selection, text, the fields are filled with the word "undefined."

    I found a PHP script Jquery here version that would probabably do the trick.
    http://StackOverflow.com/questions/3657127/jQuery-populate-text-input-from-table-based-on-select-Valeur

    Maybe someone has a version of CF. they could share?

    Thanks in advance to anyone who can point me to a solution for this code, or a better way to fulfill my need.

    <!--> destinations with address auto-fill, city, etc.
    < script type = "text/javascript" >
    function selectAddress (list) {}
    take the first element is empty
    If (list.selectedIndex > 0) {}
    var locationID = list.options [list.selectedIndex] .value;
    locationAddress var = list.options [list.selectedIndex] .locationAddress;
    var locationCity = list.options [list.selectedIndex] .locationCity;
    var locationState = list.options [list.selectedIndex] .locationState;
    var locationZip = list.options [list.selectedIndex] .locationZip;
    document.getElementById('locationID').value = locationID;
    document.getElementById('locationAddress').value = locationAddress;
    document.getElementById('locationCity').value = locationCity;
    document.getElementById('locationState').value = locationState;
    document.getElementById('locationZip').value = locationZip;
    }
    }
    < /script >
    < b >
    < td align = 'right' bgcolor = "#FFFFFF" valign = "top" > Destination name < table >
    < td align = "left" bgcolor = "#FFFFFF" valign = "top" >
    < select name = "locationID" onChange = "selectAddress (this)" class = "smallforms" > "
    < option value = "" > SELECT the DESTINATION ››› < / option >
    < cfoutput query = "allLocations" >
    "" < option value = "" #locationName # "locationAddress =" #allLocations.locationAddress # "locationCity =" "#allLocations.locationCity #" locationState = "#allLocations.locationState #" locationZip = "#allLocations.locationZip #" > #locationName # < / option >
    < / cfoutput >
    < / select >

    Others: cfinput name = "destinationNameOther" type = "text" class = "smallforms" size = "75" >
    < br / >
    < input id = "locationID" name = "locationID" type = "hidden" > < br >

    Address: < input class = "smallforms" id = "locationAddress" name = "locationAddress" type = "text" size = "30" >
    City: < input class = "smallforms" id = "locationCity" name = "locationCity" type = "text" size = "20" >
    State: < input class = "smallforms" id = "locationState" name = "locationState" type = "text" size = "2" >
    Postal code: < input class = "smallforms" id = "locationZip" name = "locationZip" type = "text" size = "8" > < br / >
    < br / >
    < table > < /tr >

    In your last code done selectAddress refers to "index" but I'm not declared or assigned. I think that you are missing 'var index = list.selectedIndex;' statement.

  • Change the content of the page based change the selection box

    Hi all

    I want to create a page with 2 box selection and 1 table below

    • Selection box
      • Box1: 1-12 (months of the year)
      • Box2: 2010-2015 (year between 2010 and 2015)
    • Table
      • Get data from view GET_DATA_SALARY. This view having a 4 column: NAME, SALARY, FAC_MONTH, FAC_YEAR
      • This table will be based on the selected value of 2 boxes above change

    Please help me solve this problem.

    Thank you

    To put it simply, add a button that submits the page.

    Add a where clause clause to your report

    where FAC_MONTH = P_MONTH

    and FAC_YEAR = P_YEAR

    Gus

  • How can we make a visible element on the screen based on the selection of an existing menu in the same screen

    February 2015 release OPA

    How can we make a visible element on the screen based on the selection of an existing menu in the same screen.

    I have a list box and a text box in the same screen.

    I have a visibility rule on the text box saying that it is only available for one of the selection in the menu dropdown.

    problem is now unless I hit the button next to the screen and return to the original screen the text box does not appear.

    Is there a solution to more to come this problem.

    Please help me

    The feature you describe is called "dynamic visibility" (http://documentation.custhelp.com/euf/assets/devdocs/february2015/PolicyAutomation/en/Default.htm#Guides/Policy%20Modeling%20User%20Guide/Interviews/Screens/Add_questions_to_screens.htm#Dynamic). It allows to control the visibility of another article on the same screen, without writing a separate rule of visibility and click on Submit.

    Using out-of-the-box functionality, you can have dynamic visibility based on Boolean values and value lists (but not regular drop-down lists).

    The example in the February 2015 User Guide based on a Boolean value on the same screen. See slide 27 of the bridge-features and benefits for an example of what it looks like to a list of value: http://www.oracle.com/technetwork/apps-tech/policy-automation/overview/opafeb2015featuresbenefits-2431219.pdf

    If you are wondering what is a list of values, see here: http://documentation.custhelp.com/euf/assets/devdocs/february2015/PolicyAutomation/en/Default.htm#Guides/Policy Modeling User Guide/Value_lists/What_is_a_value_list.htm

    See you soon,.

    Jasmine

  • When you save a file to the [.jpg] format, I wonder to choose a quality from 1 to 100. What are the changes in the created file based on the selected quality setting?

    When you save a file to the [.jpg] format, I wonder to choose a quality from 1 to 100. What are the changes in the created file based on the selected quality setting? I would like to know what changes, so in the future, I can set my camera to one who will give me the highest quality in a first time, which allows me to make cultures and always preserve the quality.

    Thank you

    Dovid

    Thank you twenty-one... your answer of common sense to me.

    so, in short, can I assume down the chosen quality over compression algorithm?

  • Quarter filter based on the selected month

    Hi all

    I need to filter the report with quarter based on a period in the report guests.

    The user selects the name of month in prompt report, the report should show the information of quarter data falling from the chosen month. I used the subreport that provide a quarter of the month. This degrades performance report, so I need a solution to find a quarter of the month in the filter of the report itself. Can anyone provide an idea on that?

    Well, now that I know the syntax, it should work for you:

    Assumptions: "month" is in the format "LUN - AA' (DEC-11); quarter is in the format "YYYY Q M" (2012 Q 2);

    Here are the pieces of the CASE statement...

    LEFT (' @{pv_month}', 3)... allows at least 3 letters ("Jan", "Feb", etc.) of the selected month...

    .. Right('@{pv_month}',2) .save the month selected two-digit year...

    Cast (Right('@{pv_month}',2) AS INTEGER)... .converts as a whole two-digit year. It is how we use the year in a calculation to determine the correct exercise when the month is September, October, November or December. In this case, (11) two-digit year is less than the tax (2012) year.

    Here are the facts:

    Q-11 MAY 2011 3 MAR-11
    JUN-11 AUGUST - 11 2011 Q 4
    SEVEN.-11 TO 11 - NOV 2012 Q 1
    DEC-11 TO 12 FEBRUARY 2012 Q 2
    etc...

    The above represents an exercise. As you can see, for the months from March to August, the exercise is the same as the selected year (all that is needed is to convert the year to two digits of a four-digit year).
    When the month is seven, Oct or Nov, the year must be incremented by 1. Month Jan and Feb, exercise is identical to the year chosen, but Dec must be dealt with separately, because even if exercise is the same as Jan and Feb (2) year should be incremented.

    Gather all this logic, you get the following:

    BOX WHEN IN LEFT('@{pv_month}', 3) ('SEP', 'OCT', 'NOV') THEN '20'. Cast (Cast (Right('@{pv_month}',2) AS INTEGER) + 1 AS CHAR). "Q 1'
    OTHER CASES WHEN leash (' @{pv_month}', 3) = 'DEC' THEN '20'. Cast (Cast (Right('@{pv_month}',2) AS INTEGER) + 1 AS CHAR). "Q 2'
    On the OTHER BOX WHEN IN LEFT('@{pv_month}', 3) ("JAN", "FEB") THEN '20'. Right('@{pv_month}',2) | "Q 2'
    OTHER CASE WHEN LEFT('@{pv_month}', 3) IN ('MAR', 'April', 'MAY') THEN '20'. Right('@{pv_month}',2) | "Q 3'
    ANOTHER BOX WHEN IN LEFT('@{pv_month}', 3) ("JUN", "JUL", "Aug") THEN '20'. Right('@{pv_month}',2) | "Q 4'
    END END END END END

    This will give you a quarter based on the selected month. You can use in the filter (Advanced > convert this SQL filter) and apply it on your column 'quarter '.

    WARNING: I did at home in order to check the syntax...

  • Dynamic action - set a value of element based on the selection of lines of report

    Hi people,

    Does anyone have an example how to set up a dynamic action, which could fill an element with the selected ID based on the selection of line of the report on the same page?

    Demo:
    http://Apex.Oracle.com/pls/Apex/f?p=19543:2

    If I select an item in the report, then I would fill in 'Selected ID' element with the value of the selected report EMPNO line.


    Later, I would use it for the display of parts of master / detail on the same page.

    Thank you very much
    Tomas

    For this sample page, add the following JS code to run when the page is loaded.

    $('.highlight-row td').click( function(){
      //fetch record id from the cell contents of first column in row
      id = $(this).parent().children('td:eq(0)').text();
      //set page item to selected id
      $('#P2_SELECTED_ROW').val(id);
    });
    
  • How to store results of the select query in the tables.

    I created a variable varray type and now want to assign some data of output of the select query in pl/SQL, as well as in reports 6i.

    You are in the wrong forum (this is for problems with the SQL Developer tool). You were the one where you have published first on the right, but not to reuse independent threads as you did.

    Kind regards
    K.

  • Create the style of paragraph based on the selection

    Is there a way to create a paragraph style based on the selection in the same way, the "New paragraph Style" dialog box without having to go through ALL the elements of style individually?

    Thank you

    Hi Ken,

    Dave (Thanks Dave) code and put it into a string:

    REM note the quotes "escaped".

    myString = "if (app.documents.length > 0 & app.selection.length = 1 & app.selection [0] .hasOwnProperty (""baseline" ")) {"& vbCr '.

    myString = myString & "myDoc = app.documents var [0];" & vbCR
    myString = myString & "var myPstyle = myDoc.paragraphStyles.add ({name:" "myNewStyle" ""}); "& vbCr
    myString = myString & "myPstyle.properties = app.selection [0] .properties;" & vbCr

    myString = myString & "}" & vbCr

    REM run now the string using "DoScript" (requires that you have a

    Instance of rem InDesign "myInDesign"...

    myInDesign.DoScript myString, idScriptLanguage.idJavaScript

    That should do it.

    Thank you

    OLE

  • Checkbox validation based on the selection of the values LOV

    I'm trying to validate a checkbox custom on the opportunity page, based on the selection of the values LOV.

    For example only when the user selects 'rating = A', the box should be able to select and save.

    If the user selects other that 'A' in the field assessment, the box should not save.

    or

    Is it possible to do, the READ ONLY checkbox, enable only when the side 'A' is selected.

    Any thoughts / help on this.

    Thank you, Kumar

    Edited by: user10833334 may 4, 2010 06:43

    There is no function to make a read-only field based on the contents of another field, it is not an option. I will list my thoughts on how you might handle this below.

    -Option 1: I recommend that you use validation to manage it. I don't know exactly to your needs, but you could write a field validation that checks to see if the flag is checked and rating <>has and sends an error message to the user, if it is not. The user would not be able to save the file until it Unchecks the box or sets the side = A.
    Advantages: User gets a message explaining the problem with the data and is forced to fix it before you save it.
    Cons: Requires interaction from the user to save and if they do not pay attention, the data may be lost if they cancelled without saving the changes.

    -Option 2: Another option would be to use the workflow to validate the registration. In this scenario, you can create a workflow that determines whether the field is out of adjustment, and if it is not correctly set, the workflow would update the box accordingly. In this scenario, you would use the 'Actions if Condition is False' also to inform the user that the flag cannot be controlled unless the side =. Then, you must set the Action "Update the values" update the uncontrolled field.
    Pros: Manages the work without user interaction.
    Cons: The con in this case, is that there is no workflow 'Before NEW record saved' trigger, so it is likely that the user sets the value incorrectly when creating the folder and it would stay like that until they update the record again.

    Some people might argue that there is another option that uses the functionality of dynamic page layout to make the field read-only, but this isn't a good option. You would need to convert using the Type of the opportunity in a way that would make use of the possibilities of lourdes for your users and I mention it only to you recommend to avoid his review completely.

    Good luck and let me know if you have any questions.
    Thom

  • Fill a combobox based on the selection of another

    Hi all

    I have a combobox that is filled dynamically. I want to fill an another combox based on the selected item in the combobox first. I use PHP to manage the connection to the database. The drop-down list box cbDivision fills very well.

    Can someone point me in the right direction?

    Here is my code:
    [Bindable]
    public var selectedItem:Object;

    [Bindable]
    private var datalist: ArrayCollection collection;
    private void resultHandler(event:ResultEvent):void {}
    DataList = event.result.data.row;
    }
    [Bindable]
    private var datalist2:ArrayCollection;
    private void resultHandler2(event:ResultEvent):void {}
    Datalist2 = event.result.data.row;
    }

    "" < mx:HTTPService url = " http://127.0.0.1/getDivisions.php"
    ID = "xmlGetDivisions".
    showBusyCursor = "true".
    result = "resultHandler (Event)" "
    method = 'GET' / >

    "" < mx:HTTPService url = " http://127.0.0.1/getFacilities.php"
    ID = "xmlGetFacilities".
    showBusyCursor = "true".
    result = "resultHandler2 (Event)" "
    method = "POST" >
    < mx:request xmlns = "" >
    < DivisionValue >
    {selectedItem.Division}
    < / DivisionValue >
    < / mx:request >
    < / mx:HTTPService >

    "< mx:ComboBox ="116"x ="60"id ="cbDivision"editable ="false"active = 'true' prompt = 'Please select' close ="selectedItem = ComboBox (event.target) .selectedItem, xmlGetFacilities.send ();"initialize =" getDivisions () "dataProvider ="{datalist}"= 'Division' labelField >
    < / mx:ComboBox >

    < mx:ComboBox = "413" x = "60" id = "cbFacility" editable = "false" enabled = "true" initialize = "xmlGetFacilities.send (); ' prompt = "Please sΘlectionner" dataProvider = "{datalist2}" labelField = "Name" > < / mx:ComboBox >


    Thank you in advance!

    No need to answer. I have it working now. It turns out that it was a problem with my PHP code.

  • Vary the accounts based on the selection of feature in data form

    Hi all

    I use Hyperion Planning 11.1.1.0.

    I have a problem by varying the members accounts on the dataform based on the selection of members of the entity of the dimension of the page.

    Currently, we use the Begbalance as a member (column) in the dataform and kept hidden. And we set the value of Begbalance-> actual values to zero for accounts that correspond to a specific entity...

    Then, on the form, I put 'delete missing data... That way I can show the accounts that should appear for an entity.

    But the list of members of the entity has more than 200, and thus also the accounts.

    Therefore, it is very tedious to do this adjustment for them...

    Someone please you suggest a better way to achieve the same * (i.e. different accounts on the dataform based on a selection of entity?) *.

    Kind regards.

    Alicia

    Hello

    You use the technique that a lot of consultants allows you to control what is displayed on a form.
    How do you set the values, if you have an excel template that you just update and then send the data to essbase it can facilitate the management of it a little.

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • How to optimize the select query executed in a cursor for loop?

    Hi friends,

    I run the code below and clocked at the same time for each line of code using DBMS_PROFILER.
    CREATE OR REPLACE PROCEDURE TEST
    AS
       p_file_id              NUMBER                                   := 151;
       v_shipper_ind          ah_item.shipper_ind%TYPE;
       v_sales_reserve_ind    ah_item.special_sales_reserve_ind%TYPE;
       v_location_indicator   ah_item.exe_location_ind%TYPE;
    
       CURSOR activity_c
       IS
          SELECT *
            FROM ah_activity_internal
           WHERE status_id = 30
             AND file_id = p_file_id;
    BEGIN
       DBMS_PROFILER.start_profiler ('TEST');
    
       FOR rec IN activity_c
       LOOP
          SELECT DISTINCT shipper_ind, special_sales_reserve_ind, exe_location_ind
                     INTO v_shipper_ind, v_sales_reserve_ind, v_location_indicator
                     FROM ah_item --464000 rows in this table
                    WHERE item_id_edw IN (
                             SELECT item_id_edw
                               FROM ah_item_xref --700000 rows in this table
                              WHERE item_code_cust = rec.item_code_cust
                                AND facility_num IN (
                                       SELECT facility_code
                                         FROM ah_chain_div_facility --17 rows in this table
                                        WHERE chain_id = ah_internal_data_pkg.get_chain_id (p_file_id)
                                          AND div_id = (SELECT div_id
                                                          FROM ah_div --8 rows in this table 
                                                         WHERE division = rec.division)));
       END LOOP;
    
       DBMS_PROFILER.stop_profiler;
    EXCEPTION
       WHEN NO_DATA_FOUND
       THEN
          NULL;
       WHEN TOO_MANY_ROWS
       THEN
          NULL;
    END TEST;
    The SELECT inside the LOOP FOR cursor query took 773 seconds.
    I tried to use COLLECT in BULK instead of a cursor for loop, but it did not help.
    When I took the select query separately and executed with a value of the sample, and then he gave the results in a Flash of a second.

    All tables have primary key index.
    Any ideas what can be done to make this code more efficient?

    Thank you
    Raj.
    DECLARE
      v_chain_id ah_chain_div_facility.chain_id%TYPE := ah_internal_data_pkg.get_chain_id (p_file_id);
    
      CURSOR cur_loop IS
      SELECT * -- better off explicitly specifying columns
      FROM ah_activity_internal aai,
      (SELECT DISTINCT aix.item_code_cust, ad.division, ai.shipper_ind, ai.special_sales_reserve_ind, ai.exe_location_ind
         INTO v_shipper_ind, v_sales_reserve_ind, v_location_indicator
         FROM ah_item ai, ah_item_xref aix, ah_chain_div_facility acdf, ah_div ad
        WHERE ai.item_id_edw = aix.item_id_edw
          AND aix.facility_num = acdf.facility_code
          AND acdf.chain_id = v_chain_id
          AND acdf.div_id = ad.div_id) d
      WHERE aai.status_id = 30
        AND aai.file_id = p_file_id
        AND d.item_code_cust = aai.item_code_cust
        AND d.division = aai.division;         
    
    BEGIN
      FOR rec IN cur_loop LOOP
        ... DO your stuff ...
      END LOOP;
    END;  
    

    Published by: Dave hemming on December 4, 2008 09:17

Maybe you are looking for