Oracle apex dynamic action set value action does not

Hello

I have two questions, that I am trying to solve. This is the scenario:

(i) 4.0 on oracle 10 g oracle apex
(II) created a form with the following page:
-P526_SES_DET_ID
-P526_VESSEL_ID (selection list)
-P526_JOB_DATE (date picker)
-P526_DAY_TYPE (list of selection with values DAY ORDINARY (if P526_JOB_DATE is a day from MONDAY to FRIDAY),)
SATURDAY (if P526_JOB_DATE is SATURDAY) and SUNDAY/PUB. HOLIDAY (if JOB_DATE is SUNDAY)
-P526_LABOUR_TYPE (selection list)
-P526_SHIFT (selection list)
-P526_NO_OF_LABOUR
-P526_RATE
-P526_SES_TOTAL

(1) I created a dynamic action of the value set on the P526_JOB_DATE page element to set the value of P526_DAY_TYPE to one of the three values above depending on the day
P526_JOB_DATE falls. Parameters are the following:

-Action: Value set
-Set type: SQL statement
-SQL statement:
Select case when (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % MONDAY % ") then" DAY ORDINARY. "
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % TUESDAY % ") then" DAY ORDINARY. "
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % WEDNESDAY % ") then" DAY ORDINARY. "
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % THURSDAY % ") then" DAY ORDINARY. "
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % FRIDAY % ') then ' DAY ORDINARY. "
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % SATURDAY % ") then 'SATURDAY '.
When (to_char (to_date(:P526_JOB_DATE,'DD-MM-YYYY'), 'DAY')
like ' % SUNDAY % ") then ' SUNDAY/PUB. HOLIDAY"
end DAY_TYPE
of the double

-Page article to submit:
-Select the Type: Item (s)
-Article (s): P526_DAY_TYPE

The SQL statement sets the value of P526_DAY_TYPE that when I replace: P526_JOB_DATE with a date like January 11, 2010 format ' and a date is taken to
Duration otherwise it doesn't.

(2) want to be able to maintain the values of P526_VESSEL_ID, P526_JOB_DATE, P526_DAY_TYPE, P526_LABOUR_TYPE, P526_SHIFT after an insert action as default values for the next create another form operation.

Like all the ideas on how to implement or to solve problems (1) and (2) would be very appreciated.

If you want to use P526_JOB_DATE in your SQL statement add P526_JOB_DATE to the "referred to submit Page:" field.

Tags: Database

Similar Questions

  • Confirm the dynamic action does not not as expected in the APEX 4.2.5

    This looks like a bug in APEX 4.2.5.  I have a page with a "Cancel" button that redirects to another page.  There is a dynamic action that fires on the button with a confirmation action and the text ' are you sure?  However, if the user selects OK or cancel in the confirmation dialog box makes no difference - the redirect is always performed.

    I found this question after the migration of a page that worked to 4.1.1-to-4.2.5.00.88 APEX and were also able to replicate on apex.oracle.com here:

    https://Apex.Oracle.com/pls/Apex/f?p=19896:2

    (Press the Cancel button in the top right of the page redirects to page 1, regardless of the user's response to confirm the popup.)

    I don't need someone to suggest the alternative code, I know how to build my own confirmation processing.  I want to just raise this as a bug as possible and see if there is a solution to make the dynamic action works as it should.

    NB I found this in the patch notes for 4.2.5.00.88 on a fix for a similar problem:

    http://www.Oracle.com/technetwork/developer-tools/Apex/application-express/Apex-425-patch-set-notes-2186274.html

    15984978

    Dynamic action front-Submit with a confirmation message does not

    Hi Tony,.

    I think the problem is that the action of the button is defined as 'Redirect page in this Application', but it must always be "defined by the dynamic Action" as soon as you have set dynamic actions 'click' to a button. Normally, which is automatically changed as soon as you create your first dynamic action of a button, and I just confirmed by creating a test button in your application that has been defined as «Redirect...» ». After that I created a dynamic action the action of the button is set to "defined by the dynamic Action.

    Is it possible that you have modified the action of the back button to «Reorient...» » ? The question why «redirect...» "does not work, it's that we cannot guarantee in what order the browser will process click on events defined with onclick in the tag button itself and those events attached as a click event handlers. This is why it is necessary that everything is defined as dynamic actions. Only in this case you will be able to cancel the treatment.

    Concerning

    Patrick

    Member of the APEX development team

    My Blog: http://www.inside-oracle-apex.com

    APEX Plug-Ins: http://apex.oracle.com/plugins

    Twitter: http://www.twitter.com/patrickwolf

    Post edited by: Patrick Wolf

  • Show / hide the dynamic Actions does not work in Windows 7 IE10 and APEX 4.2.1

    Hello

    I have a page in the APEX 4.2.1 reactive Blue theme, where show or hide page elements based on changes to other page elements and their values, in terms of JavaScript expression.

    It's that everything works well in Chrome 31.0.1650.63 m and 25.0.1, Firefox but not Internet Explorer 10. I thought it might be linked to this solution to the problem of Ajax IE10 | Code of Jason and tried their recommendation, but appears not to have contributed.

    Help please!

    Thank you

    Alex.

    I found the problem and it was my fault. One of my dynamic actions using JavaScript expression conditions was missing quotes in $v ("P1_ITEM1"), breaking the rest of the related JavaScript code. Chrome and Firefox did not care, but IE seems to be less tolerant of mistakes like that.

    Scott, thanks anyway. It is useful to know that I have that option as well.

  • Comparison of 2 numbers in dynamic action does not work

    Hello
    I am trying to create a customer validation between the 2 items (type number). If item1 > item2 then alert (the value of item1 should not exceed item2).
    So I created a dynamic action (lose focus) about item1 with pl/sql expression: p_item1 >: p_item2 as the condition.

    the problem is that the dynamic action never fires. When you set the condition never, he shoots very well. When I put the condition of value in the expression 1 = expression2, he never fires
    but when the value of expression1! = expression2, he shoots very well. It seems to me little matter what values I use they never match. is this a problem of format because I have no relative model
    the two elements.

    any idea on what is happening?

    Thank you

    Published by: ICeT on August 16, 2011 13:18

    Hello

    You may notice that the item values are always STRING. So comparing: P1_ITEM1 >: P2_ITEM2 is a string comparison.

    If you want to compare only the numbers that you need to explicitly type conversion: TO_NUMBER(:P1_ITEM1) > TO_NUMBER(:P2_ITEM2)

    brgds,
    Peter

    -----
    Blog: http://www.oracle-and-apex.com
    ApexLib: http://apexlib.oracleapex.info
    BuilderPlugin: http://builderplugin.oracleapex.info
    Work: http://www.click-click.at

  • Dynamic action does not not with the Date

    Hi all

    In my form, I created a dynamic action to be pulled on losefocus on the date of the birth column. The action returns the age in the age column. It only works if I use the date of birth hard-coded as follows:

    SELECT
    SYSDATE - AGE TO_DATE('01-JAN-2007','DD-MON-YYYY')
    OF THE DOUBLE

    It does not work if I use the actual date of entry as follows:

    SELECT
    SYSDATE - AGE TO_DATE(:P2_DOB,'DD-MON-YYYY')
    OF THE DOUBLE

    My version of the apex is 4.02 and database 11g.

    Could someone point out what I'm missing.

    Thank you
    Zahid

    Hi Zahid,

    When you want to use the values of the element of the page in a dynamic action of pl/sql, you must go to the section "Articles to submit the Page.

    brgds,
    Peter

    -----
    Blog: http://www.oracle-and-apex.com
    ApexLib: http://apexlib.oracleapex.info
    BuilderPlugin: http://builderplugin.oracleapex.info
    Work: http://www.click-click.at

  • Dynamic action does not not on the first attempt to load page. Work after refreshing the page

    4.2.1

    Hello

    I have a page with a list of selection Order_id and a display _item Product_name.  There is action dynamic PL/SQL that fills the element displayed when the order_id is changed. The problem is that when I opened the page for the first time, if I change the select order_id list, nothing happens. But if I refresh the page once, and then it starts work and the display_item is filled.

    No idea what could be the problem?

    Thank you

    Ryan

    ryansun wrote:

    On a more serious note,.

    1 when you load the page for the first time and try selecting the order_id, nothing don't be past, try refreshing the page once and you will see the option to display with the null value. What I do is. I have two tables

    Orders

    1

    2

    3

    Products

    1A

    2B

    2 Z

    3 C

    When I select the command 1, then since there is only one line of products, the displayed item will indicate A populous. If I select 2, since there are two product lines, I should see the list box.

    Doesn't seem to work and I'm sure, I'm doing something wrong.

    Difficult to be certain that as it appears that someone has been editing the page before you start watching (rather than copy the page experience their own copy). Your article P1_PRODUCT_NAME_DISPLAY he a point value / Expression 1 column = Expression 2 condition P1_HIDE_SHOW = 1 condition on that? Or any other condition of rendering?

    These conditions do not match the dynamic actions. They are applied only during the page see the transformation when the page is displayed first; When it is linked to another page; or after a branch to him. They are not applied dynamically during the activity of the user on the page. In this case, that the status is set to false when the page is rendered first, the same element does not exist in the page sent to the browser. If you want these items to appear conditionally because of the interaction with another user control, then you must initially return the elements and control their visibility using hide/show the dynamic actions.

  • Dynamic action does not work with the item change event

    Hi guys,.

    I have a problem with the dynamic Action. On my page, I have three points. (P2_X-> display only, P2_Y-> P2_Z-> button, TextField) and two dynamic actions. One of them is running javascript. When I press the button (P2_Z) this dynamic action affects textfield (P2_Y) value to display only the value (P2_X). (This dynamic works). And there is another dynamic action for the option to display P2_X. This dynamic action fires to P2_X point value changes. This DA (dynamic action) runs a plsql code and inserts the value of the P2_X element in a table (test_tbl). But when I try to do it always inserts the null value.

    The plsql code is below:

    Start
    INSERT INTO TEST_TBL
    VALUES (: P2_X);
    COMMIT;
    end;


    You have an idea? If you need, I can give the user for apex.oracle.com past.

    Thank you

    Hello

    Do you have the "points Page to submit" to the process of PL/SQL, the value of the correct item? (P2_X)

    Concerning
    J :D

  • Why dynamic action does not recognize a condition

    Running Apex 4.2 (build 4.2.1.00.08) on Windows 7, IE running.


    I'm trying to control the shape with.

    specifically, I have a field that I need peopled before running the main process.

    I have an alert action DA when the Condition is a PL? SQL expression, the content is - ': P16_FILE_NAME is null.


    With the empty field, it triggers the alert.


    I put text in the field and press the button that activates him DA, and it ALWAYS triggers the alert.


    I tried a celine that page just a couple of fields and a few buttons.


    Same conditions, the DA is to fire and give a warning about the presence of the Null field.


    Button 1 - DA real action1, send page, tick alert of DA real action 2.

    2 - the button submit page.

    Buttons 3 - copy of field1 in field 2, question to submit is 1 point field to return called Field2.


    If I enter a value field 1 and press the 1 button it says field1 is empty.

    If I press the 1 button once again, no other change is more, he says field1 is empty


    If I clear the field and press button 1 what he says is not empty, if I press it again it says it's empty.


    If I put something in Field1, and then press the 2 key, it does nothing except submit page.

    If I then press the 1 button it says that is not empty.

    Claire field and press the 1 button again twice and now is that it is empty again.


    Put soemthing in Field1 and press the 3 button to copy to Field2

    Press the 1 button and it says it's empty.


    The only way seems to recognize as being complete is if a send page was made in a separate order of DA.


    If the page submit that real action is in the same DA as the real action of check, it will not recognize the page submit until the second button.


    It must recognize, as shown in the session state as not empty and the field of the screen is also not empty, and yet he says it is empty.


    Anyone got any ideas on why this is?

    Dave T NZ wrote:

    With regard to the Condition of the DA, according to documentation, he said: "a condition is a small unit of logic which helps you control the display of regions, the items, tabs, and buttons, as well as execution of processes, validations and calculations."

    If the condition controls the execution of the DA.  Also, I can verify that by putting the condition ever and no more, it fires.

    No, in the case of the DAs, conditions of control if the code of DA is included in the page. In this regard DA conditions are more like "display of regions," the "execution of the process.

    Don't forget, the processes are executed in the database for the page and accept the transformation, while the DAs are executed in the browser when the rendered page in page of treatment. If the condition is not true then the code of DA is not included in the page sent to the browser, so it can never run, and it will not appear on the page until after another page show where the condition is true.

  • Oracle apex 5.0: pass values from one page to the other as well save you can save same value in the table.

    I use oracle apex 5.0

    Issues related to the:

    (1) I created an application where I have a form on which I have a button named 'Add', now if I click on that button values need to be stored in table.how to create! I use the dynamic button that is created by the html tag < input type = "button" > need help with this.

    (2) if the value stored in the table how the same value will be on the agenda of the calling page. ?

    New to this world of Apex.

    concerning

    Pranav shah

    http://zderadicka.EU/Apex-dynamic-actions-with-report-region/

  • Keyboard shortcuts AND Actions does not

    Keyboard shortcuts 1 keys do not work (e, g.  "P" to scroll pen options, 'B' to scroll through brush options, etc...)

    The CNTL + and ALT + seems to work fine. In addition, when I hit 'P' or 'B' selects this option, it does not work through them (brush pencil to the replacement of the color to the mixer).

    I completely uninstalled PS especially remove any previous presets (that sucked) and re-installed Photoshop since I discovered it.

    In addition, actions does not correctly or the other. I have a copyright of metadata carried out screening. I had an action implemented to always update to preset on new or open documents. Given that I have re-installed PS, this script no longer works. I made a new model of metadata from 2016, has recorded a new action and implement the handler for scripts to run on the new and open. However, whenever it is running, the script that I have saved always reverts to "Feature of models" instead of pre-recorded format that is available.

    When I type 'P' or 'B', it selects this option, but does not work through them (brush pencil to the replacement of the color to the mixer).

    Go to edit-> preferences-> tools, "If you're on previous versions": Edit-> preferences-> General

    then Unckeck 'Key Shift tool Switch use'

  • Shared action does not of course 7 to 9

    All,

    Is there any known issued with not shared actions convert Captivate 7 to 9?

    I'd build one to replay a slide from the start, but now that we've updated the action does not work... and I can not understand how to open it to see what I did in the first place.

    Help with this dilemma would be appreciated.

    v/r

    Jay

    Joint actions have been improved in CP8 compared to CP7, because the variables and literals have been added as parameters. This could be the cause of your problems.

    Recently, I explained two scenarios for slides of Replay, maybe this can help: BACK (slide) - Captivate blog button

  • See the value of zero instead of "the value entered does not match the format of the field [].

    I use the simplified notation filed to perform subtraction on a budget form.

    They all have an excellent work and have no problem display a value of zero when it's a simple subtraction (value1-value2).

    However, on my last field I want to take the total income and subtract what I spent (approximately 40 fields) and get a balance zero.

    When I try to do it I get this warning "the value entered does not match the format of the field [].

    The calculation works fine and displays the correct value for all the foregoing ".» 01 "and displays negative numbers. 01 "and underneath as well (if I go on the budget), she just may not show a zero, which is my goal for this equal to zero each month.

    I tried to watch if the forms and have not found an answer that works even for my situation.


    Happy to post the form here, just do not know how to do it.

    Thanks in advance,

    The custom calculation script may be something like the following:

    Get the value of field of income, as a number

    var v1 = + getField("Income").value;

    Set up an array of domain names

    var aFieldsToSubtract =]

    "ThithesB,"

    "TailleB,"

    "EFundB,"

    "MortgageB,"

    "HomeItemsB,"

    "HomeRepairsB,"

    "ElecticB,"

    "GasB.

    "WaterB."

    "SewerB,"

    "TrashB,"

    "PhoneB."

    "InternetB."

    "AutoInsB,"

    "UmbrellaB,"

    "IdentityB,"

    "CosmeticsB,"

    "ToiletriesB,"

    "PocketEBB,"

    "PocketCBB,"

    "GiftsB,"

    "HouseSuppliesB,"

    "PersonalOtherB,"

    "PersonalOther2B,"

    "GroceriesB,"

    "RestaurantsB,"

    "ClothingB,"

    "CarGasB,"

    "CarRepairsB,"

    "CarOtherB,"

    "MedicalBillsB,"

    "MedicalOtherB,"

    "EntertainmentB,"

    "VacationB,"

    "DebtCarB,"

    "DebtStudentLoan1B,"

    "DebtStudentLoan2B,"

    "DebtStudentLoan3B,"

    "DebtCreditB,"

    "DebtOther1B,"

    'DebtOther2B '.

    ];

    Subtract the values in field

    for (var i = 0; i)< afieldstosubtract.length,="" i="" +="1)">

    v1-= + getField(aFieldsToSubtract[i]).value;

    }

    Set this field value by rounding the result to the nearest

    Event.Value = util.printf ("%.2f", v1);

    Do not think of this as a band-aid, think the correct way to perform the calculation, because it is. Note that "Thithes" may be a spelling error.

  • ORA-14313: value 'Limit' does not exist in the partition DATASET_OTHER

    Hi friends,

    OS: Linux
    Database Version: 10.2.0.2.0

    I wanted to add a partition to one of my partitioned table "mapping". Then when I tried to reverse the partitionwith the command below... I got the error ora-14313 code.
    Command Used:
    
    ALTER TABLE MAPPING SPLIT PARTITION dataset_other VALUES ('CAP') INTO (PARTITION dataset_CAP TABLESPACE TBS_MAPPING_CAP, PARTITION dataset_other);
    Error :
    
    ALTER TABLE MAPPING SPLIT PARTITION dataset_other VALUES ('CAP')  INTO (PARTITION dataset_CAP TABLESPACE TBS_MAPPING_CAP, PARTITION dataset_other)
                *
    ORA-14313: Value 'CAP' does not exist in partition DATASET_OTHERERROR at line 1:         
    Please suggest what to do and what is the reason for this? coz of some other partition spilit command executed successfully.

    Concerning

    Umesh

    Umesh Gupta wrote:

    Here are a few recent records in table

    select table_name,partition_name,tablespace_name,high_value,partition_position from USER_TAB_PARTITIONS order by partition_position
    
    TABLE_NAME     PARTITION_NAME     TABLESPACE_NAME     HIGH_VALUE     PARTITION_POSITION
    
    MAPPING    DATASET_NAP           TBS_MAPPING_NAP   'NAP'     379
    MAPPING    DATASET_MAP           TBS_MAPPING_MAP  'MAP'        380
    MAPPING    DATASET_SAP           TBS_MAPPING_SAP   'SAP'        381
    MAPPING    DATASET_OTHER       TBS_MAPPING          DEFAULT            382
    

    Have you checked other values of 378 score very carefully. (Normally) you get the error message means that the value exists somewhere else already.
    You could also point out the high_value_length, just in case where the high_value isn't really what it looks like (e.g. some backspaces hide certain content).

    Concerning
    Jonathan Lewis
    http://jonathanlewis.WordPress.com
    Author: core Oracle

  • Set Up Wizard does not recognize printer

    Set Up Wizard does not my Photosmart 5160 when you use Mac OS 10.5.8, although the Mac recognizes and allows to print the documents. However I can't use create HP for printing on a DVD. If I boot with OS 10.4, it works perfectly, don't want the hassle.

    You can have the software wrong under 10.5.  Download the latest version of the software for your printer from the "Support & drivers" link at the top of this page.

  • Hoping to change from English into Chinese language. By Edition-preferences-language setting, but it does not work.

    Simplified Chinese WIN 7,64;

    Install acrobat DC;

    but the system installs the English version by default,

    Hoping to change from English into Chinese language.

    By Edition-preferences-language setting, but it does not work.

    Thanks for the help!

    Cloud of swap language http://helpx.adobe.com/creative-cloud/kb/change-installed-language.html

Maybe you are looking for