Unique name for a page element validation.

Hello. I have 2 items on the page: P2_DNAME and P2_LOCATION. Both are text fields. What I want to do, is that I need to create a validation. The P2_DNAME field must be unique. When entered a value in this field, he must check with the DEPT table and make sure there unique name.

To achieve this, I created a name Unique service name validation. Who checks with the query "select 1 of the Department where dname =: P2_DNAME' and throws an error message." This validation is also executed when the user clicks the submit button. But I want that it will be executed when the user moves to the next field.


My validation also does not work. I reproduced it in oracle apex.com

WORKSPACE: XXKIRAN

USER name: kiran28. [email protected]

PWD:kiran123

App.No:94949

Page no.: 2


Can someone please review and tell me what I'm missing?

Hello

Please, take this as a guideline how do it, not as a solution. You can for example create another 'helper' and return the result of your posting in routine (instead of the actual input box), and then you can create appropriate dynamic actions that handle the change event of the article that you return your result of validation. To be more precise...

Create an element of P1_DEPT_VALIDATION_RESULT, in your PL/SQL code, assign a value to it according to the DEPT_COUNT as

if dept_count = 0 then
     :p1_dept_validation_result := 'valid';
else
     :p1_dept_validation_result := 'invalid';
end if;

and add this in the field "Article (s) to return". Then manage its change event (just change event cannot be removed, so don't forget to switch the button to "Suppress the event" non).

Pavel

Tags: Database

Similar Questions

  • Deployment of ADFLibrary: provide a unique name for the resources in this project

    JDeveloper 12 c.

    I'm deploying an application as a library ADF - it will be used my multiple applications.  So it's a bit generic. Sometimes it is OK and other times it gets stuck... See the ChangeLog

    What do mean exactly by ' resourceprovide a unique name of the indicated "? 

    What should I name the files?  xyz_abc_appNotices.jsff or the directory structure has to change?

    Thank you!

    Stuart

    [16: 38:44]-deployment began.  ----

    [16: 38:44] the target platform is Java EE Standard.

    [16: 38:44] analysis of the dependence running...

    [16: 38:44] building...

    [16: 38:48] deployment of profile...

    [16: 38:49] WARNING: the commonly named resources below could cause errors of reusability to your consumers.

    Provide a unique name for the resources in this project, or start with a different project.

    appNotices.jsff

    appNoticesMain.jsf

    [16: 38:49] Mobile WEB-INF/adfc - config.xml for META-INF/adfc-config. XML

    Well, Yes, it would do. The warning say you that your library resources should use unique names, that I hope are not used by other libraries. From the resources app Strip is common chance is that it will be a duplicate.

    Timo

  • Appeal procedure for a page element

    Hi friends,

    I have a page element and I need to return a value for the page element by using the procedure. For this I created a procedure
    create or replace procedure xx_test_proc7(a number,b out varchar2) 
    as
    begin
    select sum(sal) into b from scott.emp where deptno=a;
    end;
    And called this procedure as the below in the section by default, by specifying the type as 'the plsql function body '.
    declare
    x varchar2(20);
    begin
    xx_test_proc7(20,x);------>20------>hardcoded
    dbms_output.put_line(x);
    end;
    But this element does not receive the value of the procedure.

    What is the problem with her friends.

    Brgds,
    Mini

    Hello

    Your code should be based, so try

    declare
    x varchar2(20);
    begin
    xx_test_proc7(20,x);------>20------>hardcoded
    RETURN x;
    end;
    

    Kind regards
    Jari

  • Result passage of PL/SQL code for the page element

    Hello

    I have created a process in after the header to fill data to the page of the form elements.  The pl/sql code is like bellows.  Then I got the error message:

    ORA-06502: PL/SQL: digital or value error: character number conversion

    My question is that I do not see the difference in format between the page element and block pl/sql variables (e.g. : P31_STUDY_ID vs v_P31_STUDY_ID), they are either numeric or text field (in fact I have hidden field, but don't see conversion back to the digital field solved the problem).  And don't see needs to set the format mask.  Is there another way to detect the column that causes the problem, or if there is a syntax error with my assignment (from the variable element on the page)?  Thank you very much!

    ============================

    Declare

    number of v_P31_STUDY_ID;

    number of v_P31_STUDY_SITE_ID;

    v_P31_STUDY_SITE_NAME VARCHAR2 (255);

    v_P31_STUDY_SITE_NUM varchar2 (10);

    number of v_P31_STUDY_SITE_NAME_NUM_ID;

    number of v_P31_STUDY_SITE_OPEN_STATUS;

    v_p31_comments VARCHAR2 (255);

    Start

    Select

    tbl_study_site.study_id,

    tbl_study_site.study_site_id,

    study_site_name,

    study_site_num,

    STUDY_SITE_NAME_NUM_ID,

    STUDY_SITE_OPEN_STATUS,

    Comments

    in

    v_P31_STUDY_ID,

    v_P31_STUDY_SITE_ID,

    v_P31_STUDY_SITE_NAME,

    v_P31_STUDY_SITE_NUM,

    v_P31_STUDY_SITE_NAME_NUM_ID,

    v_P31_STUDY_SITE_OPEN_STATUS,

    v_p31_comments

    of tbl_study_site, tbl_study_site_attrib

    where tbl_study_site.study_id =: p30_study_name

    and tbl_study_site.study_site_id = tbl_study_site_attrib. STUDY_SITE_ID

    and tbl_study_site_attrib. STUDY_SITE_ATTRIB_ID =: P31_STUDY_SITE_ATTRIB_ID;

    : P31_STUDY_ID: = v_P31_STUDY_ID;

    : P31_STUDY_SITE_ID: = v_P31_STUDY_SITE_ID;

    : P31_STUDY_SITE_NAME: = v_P31_STUDY_SITE_NAME;

    : P31_STUDY_SITE_NUM: = v_P31_STUDY_SITE_NUM;

    : P31_STUDY_SITE_NAME_NUM_ID: = v_P31_STUDY_SITE_NAME_NUM_ID;

    : P31_STUDY_SITE_OPEN_STATUS: = v_P31_STUDY_SITE_OPEN_STATUS;

    : P31_COMMENTS: = v_p31_comments;

    end;

    =============================

    Identify the root cause. He's always on the format of the column, there is an error.  Thanks for your help.

  • Unique name for the SCORM content downloading 3rd party LMS

    I use a 3rd party LMS and trying to download content.  I publish the release without any problem, which creates a file filename.zip.  Regardless of which is the file name, when I go to browse by transferred in the LMS, the name is always "ADOBE_PRESENTER".  That's why I have a lot of different packages that all look the same.  Is there a setting in the host that can be done that will make this unique name?  I talked with the support staff to our LMS, and they said they did not have this problem with other guests.

    Hi Michael,

    In this case, it is really hard to determine what information is the LMS pick up to name the course.

    If we could get the information of LMS, which file is that it uses for naming during output zipped folder, we try to look into this.

    In addition, generally we have always the ability to rename our classes uploaded to the LMS. For example. When the publication of an LMS as scorm cloud, the downloaded course is always named as Adobe_Presenter and users generally rename their courses to keep track.

    Please mark this answer as correct if you find it useful.

    Let me know if you need additional assistance.

    Kind regards
    Zeeshan Hussain

    Adobe Presenter Engineering Team

  • Search MediaLocation for a page element

    Hello

    I am writing a plugin InDesign that needs to ask the MediaLocation for any movie on a page.

    I found 2 ways: first by selecting the page element and access the location through IMediaSuite:

    IActiveContext * iActiveContext = GetExecutionContextSession()-> GetActiveContext ();

    ISelectionManager * iSelectionManager = iActiveContext-> GetContextSelection();

    Ms. InterfacePtr < IMediaSuite > (iSelectionManager, UseDefaultIID());

    If {(ms)

    MediaLocation loc;

    MS-> GetMediaLocation (loc);

    }

    However, ideally, I do not have first select the page element.

    The second way, I found avoids having to select, but does not work for movies remotely because they have no link:

    LinkUID UID is Utils < ILinkUtils > ()-> FindLink (item);.

    LinkManager InterfacePtr < ILinkManager > (db, db-> GetRootUID(), UseDefaultIID());

    ILink * link = linkManager-> QueryLinkByUID (linkUID);

    InterfacePtr < const ILinkObject > linkObj (: GetDataBase (link), link-> GetObject (), UseDefaultIID ());

    InterfacePtr < const IMediaInfo > mediaInfo ((IMediaInfo*) linkObj-> QueryLinkedObject (IID_IMEDIAINFO));

    InterfacePtr < const IMediaContent > mediaContent (mediaInfo, UseDefaultIID ());

    MediaLocation loc = mediaContent-> GetLocation();

    Is there a way I can get the MediaLocation for movies the and remote, without having first to select the page element?

    Thank you

    Liz

    Hi Liz

    You need not search for the link to access IMediaContent. Access you IMediaContent of page elements that are:
    -kMediaPageItemBoss

    -kMoviePageItemBoss

    -kSoundPageItemBoss

    So if you have a UIDRef to the graphics framework (kSplineItemBoss), you must use IHierarchy interface to obtain the correct page.

    You can check if this is the right page using

    Utils()-> IsMediaItem (kMoviePageItemBoss, yourUID, youDB)

    And then

    InterfacePtr mediaContent (youDB, yourUID, UseDefaultIID());

    MediaLocation loc is mediaContent-> GetLocation();.

    PMString theStr = loc. writing;

    MediaLocation, you can get the information if it's remote URL or local file

    Concerning

    Bartek

  • How to get LR using a unique name for each file?

    Hey there,

    I see that LR does not change the name of the file when there is already a file with the same name in the import file, but once you choose another folder it does not matter the file with the original name. I just realized that over the years using folders such as photos 2009 Photos 2010 and so forth, I have three or four times the files with the same name. Is there a way to tell LR to always use unique names when importing?

    Use a naming date-description model - sequence.ext to rename as you import (or if you prefer after importation). This means that you have never duplicates unless you for some weird reason use the same description for two sets of files on the same day. And if you need to do exactly that, just the starting number of the second/third batch of files be a number greater than previous batch on the same day.

    You can configure what ever format naming you want in file rename dialogue and have as a default.

    Leaving the file names as they come out of the device application in big trouble as invariably they're going to duplicate, which is not an even if good idea in different folders.

    F2 to rename the dialog when in the library.

  • How to know the URL names for the pages of my Web site before you download on the internet?

    I would like to know; names (URL) that each of my pages (created in muse) will be before I have to download my Web site?

    How do knowing that? I need it because I need to know some links, for some buttons etc.

    The only URL that will change is the homepage (the first page in the plan view), which will always be equal to index.html, since web servers are set to get it, in order to serve the first page of the site.

    Unless you have a specific reason to do this, you don't need to enter the URL of the page directly, as you can get the list of hyperlink pages and Muse will create the necessary link code. It is better to do this way, given that the URL will be automatically updated if you change page names.

    David

  • How to set a default value for a page element

    I work with an array of facilities that has the name and the address. The user can add information to the contact person on a separate page. Because the address of the establishment and his contact is generally the same, I want to add a default value to the contact address. The installation page is on 201 and the link to add a new line of contact is on page 202. I showed in the default value: P201_street to the address of the contact. But, when I run the page, contact the address field shows the: P201_street, not the address of the actual plant. Do I leave? Must be something obvious?
    Thank you very much.
    Judy

    Hello

    Use: P202_STREET1 for PL/SQL expression, or just P202_STREET1 if you use the value of the item condition.

    See you soon

    Ben

  • Merge to PDF - create a unique name for each PDF file

    I have been regularly mail merge documents to PDF using Microsoft Word and Microsoft Excel for quite some time, but once I have a long list of PDF documents I then have to rename each to what it must be rather than 'PDFMailer123 '.

    Which would save me a lot of time with the renaming of the documents is so trying to create the PDF (with Adobe Acrobat), he was able to pick up a field in the worksheet excel information fusion to name the document.

    Is there a way to do this?

    Yes, it can be done if you do direct mail using a script.

  • Assign value APEX URL of the page to the redirect of the page element

    Hello
    I have the following hard coded URL routing traffic on page 10:
    href = "f? p = & APP_ID.:10: & SESSION. ::: 10 : »

    However, now I have logic to determine the button of the page which should route traffic and I'm storing in a Page element called P6_PAGE_ROUTE (the value is 10 or 23). How can I get the URL to direct traffic based on the value in P6_PAGE_ROUTE? I did some research and I've tried using the & P6_PAGE_ROUTE. but it does not work:

    href = "f? p = & APP_ID.: & P6_PAGE_ROUTE. : & SESSION. : & P6_PAGE_ROUTE. : »

    Thanks in advance for any help!

    URL addresses by passing the values generally have this format:

    href = "f? p = & APP_ID.: & P6_PAGE_ROUTE. : & SESSION. : ITEM1, ITEM2, ITEM3:VALUE1, VALUE2, VALU3

    Where,
    Question 1 has value 1
    question 2 has value 2
    and point 3A of value 3

    So the stuff LHS of the *: * must be the name of a page element

    + PS: Ensure no space after the comma as its URL. I fell for the first time and it is difficult to meet. +

  • model page and page elements

    I need to display the title on a set of pages information. I changed my page template and the string substitution put (& MY_TITLE.). Then I tried to add the element of hidden page (MY_TITLE) on each page and fill it with database information. But the top does not have page elements with the same name, even if they are on different pages.

    I need something as part of the extended page, which will be available only in the current page and will not affect other pages, or a kind of double string substitution when the first name of the page element is built and then the value of this element of the page is taken.
    How can I solve my problem?

    Published by: 866569 on July 8, 2011 12:43

    Published by: 866569 on July 8, 2011 12:50

    Hello

    You can use application article or article page zero.
    Then use calculation on each page to set the desired value for this element.

    Kind regards
    Jari

  • How to retrieve a value of page element in another page?

    Hello

    How to retrieve a value of page element in another page?

    say P55_COURSES_TO_EVALUATE is my name of the page element, and it is a selection list. Based on the value selected in the next page I see the details of the selected value shd and for that I need P55_COURSES_TO_EVALUATE value in the following page. How to do it? When I try to retrieve the values it simply returns nothing.
    Pointers would be really useful.

    Thanks in advance.

    Hello

    Could you please how you try to use it?

    If you set the value to the P55_COURSES_TO_EVALUATE element and submit the page, the value is stored in session state.
    Then you can use this element in any page as

    :P55_COURSES_TO_EVALUATE
    

    You cannot access page value in javascript/jQuery to other pages like

    $v('P55_COURSES_TO_EVALUATE')
    document.getElementbyID('P55_COURSES_TO_EVALUATE')
    $(#P55_COURSES_TO_EVALUATE)
    

    Because the item is not on the other pages. In javascript from other pages, you can use

    var a = '&P55_COURSES_TO_EVALUATE.';
    

    Kind regards
    Jari

  • How to hide post text of item in page element

    Hi friends,

    I have a page titled Justification in which under the element text of this article post I give as
    <br><div style="color:blue" font size="1">(240 char max)</font></div>
    Inorder to view a note behind the element.

    But the element of justification page must don't come until after checking the page of another element called reason (which is an option button). So for this I wrote a DA(hide/show) for display of the justification of the point of the page only when the page right element is checked.

    But the problem is that the text of element position within this element of page Justification does not hide with this element (in the DA).


    How can I hide the text of item post in the justification for page element. so I can see this text when the reason page element box is checked as well as the justification for a page element.

    Brgds,
    Mini

    Hey Mini,

    I just write bad :/

    The function is $x_Hide () not $p_Hide ();

    Thnx

  • [AS] Cannot remove a Page element

    I'm confused as to how to remove a page element. It is a jpeg embedded in a document of AI, I can remove it by selecting and executing a simple script like this:

    Tell application "Adobe Illustrator"

    say active document

    delete selection

    end tell

    tell the end

    However, if I try to find and delete as part of a larger script, it won't clear. No error is thrown and everything else in the script works, but the item not be deleted. Here's a piece of the script that I had hoped to find and remove the element. Note that the script can find the item very well because I am able to copy its position property and it allows to place another point in that I paste.

    the value question for each page element of the document 1

    Repeat with e from 1 to the number of question

    put pourla to the point e of question

    If width of pourla = 26 may

    on theBounds position of pourla

    delete pourla

                        paste

    Paster point value 1 of the selection

    theBounds the value position of Paster

                   end if

    end repeat

    Any ideas would be a great help. Thank you.

    You might have better luck looking for elements of running through all the elements of the page if you want to remove is always an embedded JPEG images.

    This is an example

    Tell application "Adobe Illustrator"
    the docRef active document value
    Define rasters (each point on the page of the docRef) whose class is the point of frame
    Remove rasters
    Close docRef save Yes
    tell the end

Maybe you are looking for

  • Air iPad does not illuminate

    The symptom is more simply not turn on: It happened a few times before (within two weeks) that the ipad just froze and turned the icon apple black and white background. After working in the home/power together for a while, he fixed the situation. Las

  • Support SME 3.0

    With SMB3.0 now in the latest version of Samba, I wondered when SMB3.0 would be available in the ix series. competing as Synology and QNAP already have this built-in support... (for a while)... It would solve my problems (hopfully) with slow file cop

  • 64 bit Vista having bad update

    I recently boguht a new computer HP laptop, Pavailion dv2 1039wm, among other problems he struggles to update to vista.  Safely update program download updates in the background with no problems, but when I restart the computer to install updates pro

  • the desktop application icons are highlighted in a blue box

    Original title: Desktop The desktop application icons are highlighted in a blue box, how do I get rid of the box?

  • wandering Web page

    router bought belkin, hav configuration admin acct on win xp. accenditly loaded on rectrictd now has my mini show connect to the router, but can not get on tried to disable say cuz of Protocol can not only support plun and play or hav may be iniated