How to display a validation on a modal dialog error based on a unique constraint?

Hi all

Apex 4.1

See example on apex.oracle.com:

Workspace: EDIAZJORGE

User name: TEST

Password: test123

Application: 55036 - Validation of modal Page

I have a page with two elements, to make and model, where the user will be able to enter the model, say, a car and use a pick to dolist. If make does not exist, the user can click on the [+] button that opens a modal dialog box to add a new do.

Everything works fine except when I try to insert a double do, which triggers a unique constraint violation error:

AJAX call back Server error ORA-00001: unique constraint (EDIAZJORGE. MAKE_UK1) violated to execute the PL/SQL Code

I want to enter this event and inform the user about an error inside the modal dialog box, but I don't know what is the best way to achieve this. My guess is that I'll have to make an Ajax call to run an application process and capture the exception of DUP_VAL_ON_INDEX, but I'm not very familiar with the Ajax part.

Any suggestions?

Thank you

Erick

I'm sorry Erick, I was in error. You always get an alert but with a nicer message. The actions of builtin DA do not allow interaction with them, so no way to manage the return of ourselves.

In light of this, I copied the page in enforcement 77635 1-2 and made some changes to it. Basically, I copied the code to Jorge and modified so that it uses $.ajax instead of apex.server.process. I much prefer it to htmldb_Get - you shouldn't really use it either. More $.ajax has the advantage of this apex.server.process is based on it. That should work well on 4.1.

Sorry Jorge, won't steal the Thunder, I guess I was... bored? And decided to do some apex?

Tags: Database

Similar Questions

  • InDesign Slow Snot in January: still active modal dialog error

    You know how Indesign takes an obscene amount of time to launch on OS X Yosemite (on five different machines with a variety of configurations - so this isn't us)?

    Well, our team, just waiting and waiting and waiting for launch InDesign constantly makes the mistake of re-launch (double-click) the same document. Of course, it's stupid. But since there is no way to know if InDesign is ever going to get out of bed and get to work and the understandable error. And it happens all the time.

    But here's the problem - and it's bug from Adobe:

    Then you get the error "always active Modal Dialogue." That you can not turn it off. You need to force InDesign to quit smoking. Who sometimes then corrupts the document you spent weeks. It's good thing, you have a backup system, isn't.

    My question is:


    Is there anyway to clear the error dialog box?

    ADOBE CAN FIX THIS BUG FINALLY AFTER FOUR VERSIONS?

    https://www.adobe.com/cfusion/mmform/index.cfm?name=wishform for bug reports or feature requests

  • Possible to update the display of the art behind the modal dialog box?

    I am trying to create a plugin that changes the attributes display and art in a modal dialog box. I would like to change to show that they are made in the dialog box before the dialog box is disabled.

    From now on, it seems that the view is only updated when the dialog box is disabled.

    Is there some registrant can I send, or on function call to trigger a new drawing of in my UIController?

    Again, I think I answered my own question. By the discussion here: AI Document-view synchronization problem

    I called AIDocumentSuite-> RedrawDocument() 2 x. That seems to have done the trick.

  • How to display the icon of the narrow on the title bar of dialog modal dialog box on Mac?

    Hello world.. !!

    I have a question... When we display a modal dialog box on mac, it does not contain a close icon in the upper left corner. If the type of dialogue Panel and then the close icon appears. What do I do to make the close icon shows the dialog box when its type is modal... for example, kADMSystemAlertDialogStyle... ?? Something should be changed in the resource file in the section that defines the specifications of dialogue mentioned below... ?

    resources 'DLOG' (kMyDialog, 'My window', purgeable) {}

    {0, 0, 580, 570}, / / up, left, down, right

    5, / / movableDBoxProc

    0 x 0, / / is not visible at the start

    0 x 0, / / no close button

    0 x 0, / / application options

    18504, / / resource ID

    "My box", / / title of dialogue

    0x0 / / positioning noAutoCenter dialogue

    };

    I tried to change the values for the "no close button", but as there is no document that describes what are the valid values for this field, so I had no success...

    Help, please...

    Thank you!

    ADM has been deprecated for some time. You really shouldn't use it.

  • How to set the location of the display of the modal dialog box?

    Hello

    Setting the height of a modal dialog box seems to influence the position of the modal dialog in the window.

    (See also the Position of the modal dialog box)

    If anyone can confirm this? And if so, how can I handle it?

    Thank you

    Jos

    Hello

    Thanks John: How to persist APEX dialog size and position. HardLikeSoftware

  • Foglight display size of the modal dialog box

    Hello

    Dashboards drilled down, I can choose how to display the detailed view.  So I chose popup--> the modal dialog box.  Now when I click on a line, instead of leading me to another page, it will display a popup window and view detail info.  The popup window has a fixed size and I can't change it.  Is there a way to change or set a certain size?

    Yes. You must change the settings from the view of exploration down, not the parent view. The settings are located under Configuration-> Options of Popup. You can play with the default size, size maximum and scroll bar to display the drilled down. It took me a while to figure this one out myself.

  • Does anyone know how to display along with the app on the Mac App Store in the Sierra of MacOS?

    Does anyone know how to display along with the app on the Mac App Store in the Sierra of MacOS?

    I've just updated to Sierra. Since the upgrade did several reboots. When I discover an app the side also shows "4 +" or similar and I click on the note to view reviews and ratings of customer, a blank screen appears. Everyone knows this or have a way to solve this problem?

    I see even here in Seattle, so I think the question is about the end of Apple.

    By the end of 2012 Mac minis, macOS?  Watch 38 mm silver AL, watchOS 3; iPad 2 Air & iPhone 6 + iOS 10.0.1;  Apple Airport Express

  • How to display date / time in the browser console?

    How to display date / time in the browser console?

    You can set through the Options (gear icon) page in the Web Console (Firefox/tools > Web Developer).
    This applies to the browser console and the Web console.

  • How to display the width of the page or the big screen in firefox 11 automatically?

    How to display the width of the page or the big screen in firefox 11 automatically? I know how to Ctrl +, ctrl - and ctrl 0, but is there a way to define 11 firefox to automatically set the page viewing by default "page width" or full screen (F11 not)?
    Help, please. Thank you.

    You can use an extension to set a page zoom and the size of the default font on the web pages.

  • How to display bookmarks as default to the bottom of the left side of the page in Internet Explorer

    How to display bookmarks as default to the bottom of the left side of the page in Internet Explorer

     opens the Bookmarks sidebar or you can use View > Sidebar - Bookmarks to open it. It will stay open until you close it, and if you close Firefox when it is open, it should appear the next time you open Firefox.
    
  • FCP 7 How to display several takes both

    I'm running FCP 7 on a Macbook Pro with OS 10.10. Trying to figure out how to display several takes of the video on my calendar running at the same time. Mounting a show of live music from four cameras simultaneously turned and want to choose between shots while seeing the four outlets. Is this possible?

    Multiclip editing:

    https://documentation.Apple.com/en/FinalCutPro/UserManual/index.html#chapter=42% 26section = 12% 26tasks = true

    MtD

  • How to display scrollbars on Type Def

    Dear programmers,

    Question:

    Does anyone know how to display scroll bars in a window of Type Def after that both have been disabled?

    Background:

    I have a several projects where the scroll bars do not appear on some Type definitions. It is possible that they may have been disabled by other programmers in the past. This prevent me to see big bouquets stored inside and I have to physically move the entire cluster which takes a long time. I can't find a way to reactivate them (assuming both have been disabled).

    You can reproduce my problem if you start with a new Type def...

    Disable the two scroll bars...

    After that the scroll bars disappeared, how do I return? Using the control properties > appearance window will not allow the user to customize the scroll bars, and is no longer a right click menu available because you have to click with the right button on the bar itself scrolling.

    For those who work for the glory, I can provide the !

    It's funny, I couldn't find a simple way to do it either!

    You can try this code snippet. Please backup your control before you run it. Just browse the constant path to the location of your command, then run.

  • How to display on my screen 2 different applications at the same time?

    How to display on my screen 2 different applications at the same time?

    Hello

    The best place to ask would be the forums for answers corresponding to your version of Windows.

    Answers - Windows Forums
    http://answers.Microsoft.com/en-us/Windows

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

    If you have Windows 7 with Aero - click with the right button on the taskbar at the bottom of the screen and click on 'show windows '.
    Side by Side.

    For all versions of Windows:

    You could also reduce less than full screen using the small box to the left of the red X at the top right
    and then resizing windows as you want.

    I hope this helps.

    Rob Brown - Microsoft MVP<- profile="" -="" windows="" expert="" -="" consumer="" :="" bicycle=""><- mark="" twain="" said="" it="">

  • How to display the drop-down list box in MS excel by using labview report generation toolkit? pleasepost code block diagram?

    How to display the drop-down list box in MS excel by using labview report generation toolkit? Please post the block diagram of the code so that I can able to generate from the drop-down list box in excel with the menu drop-down...

    Like this. (edition, use the reference forms instead of the reference to the worksheet)

    Ben64

  • How to display the list of components in ultiboard 10?

    The DRC report the errors where the components that are no longer in the design have been removed. How to display the list component and then remove them from the netlist to stop this?

    Ultiboard reported missing errors of component (part 'X' is not about design) because the part is always referenced by a net. To fix this, you must remove the part of the net. Following the steps below to remove the part form the net.

    1 tools > Netlist Editor

    2. for each network that the part has been connected to, select the Net (upper-left).

    3. Select the tab of pine trees, select the part and it is the PIN in the dialog box, then click on remove

    The problem is when the part is removed, I see no easy way to determine the threads you need to remove the part of. I entered this as a feature request to make this easier, but as a workaround, you can put part and say Ultiboard what the missing part, then search the net names on the pins and remove the part of these pins

    1 place a piece with a lot of pine trees (for example the part that was removed, or for example through Hole technology > Connectors > SIL & headers > HEADER2X9). When you place the part, make sure that the RefDes matches the RefDes of the part which has been removed.

    2. once the room is placed, you should see rats nest lines that connect the part to the nets.

    3 Zoom on the pins. You should now see the net name on each of the axes. For each of the pins connected, remove it from the net as described above.

    4. remove the part that you placed.

Maybe you are looking for

  • Re: Qosmio F20-137 - after I installed Windows 7 I have no sound

    I installed Windows 7 on my Qosmio F20 and all the drivers have been installed by windows update after I connected to the Internet.I can play music and videon to files in Windows Media player, but there is no sound in speakers or if I connect the hea

  • "Residue" in general polynomial Fit function

    Did anyone of you statistics fans understand how LabVIEW calculates the output of 'residue' in the service of "General polynomial worthy?  How is it related to the R ^ 2 value on a polynomial trendline Excel. I tried to figure this out for hours, but

  • BlackBerry Z10 transmits a text message

    Can't for the life of find me a way to send a text message I feel stupid same announcement but ideas?

  • BlackBerry smartphones alerts, reminders and Notifications

    I am a new user of verry of the Blackberry Tour (Verizon's Service). I noticed the following: If a call or a text message arrives, my phone's ringing tone desired... but if I missed a call or a text message there is no reminder plays a sound every 5

  • Images for the retina display remain unclear

    I just published my first site in muse, and I used a bunch of miniatures made from the buttons of photoshop. For the desktop version, they are all 300 x 169. For the mobile version, I made all the 600 x 338 and then transformed their 300 x 169 in Mus