AltKey Uniqueness Rule firing when it shouldn't

Hello,
I am using JDev 11.1.1.4.0.
I have a 'Name' field that has Altkey for uniqueness rule. It works fine. In fact, it works too well that the rule fires when it shouldn't.
So I was looking for an example to execute the validation conditionally, for my case only when 'Save'.
Any suggestion/comment appreciated.
Thank you
Bones Jones

No reason in particular, when I created the class, FlashBuilder put it in there (I'm using Flash Pro CS5 + Flash Builder 4). I read that it calls it by default when the class is constructed, so having it in or out didn't really matter. I did comment it out with no luck, but I ended up shifting around the timeline quite a bit today and the problem has gone away. It seemed to only do it when it was in the first frame.
Thanks for your help, I'm going to investigate it further when I have time just for reference, I'll post anything I find here.
-Nick

Similar Messages

  • REMOVED_FROM_STAGE event firing when it shouldn't...

    Hello everyone,
    Wondering if someone has seen this before. I have an application that has a few navigation points on the main timeline. The document class stops the movie at the first frame, and the "home" movieclip's class has Event.ADDED_TO_STAGE and Event.REMOVED_FROM_STAGE listeners on it. Funny thing is, it is calling the ADDED function as normal, then firing the REMOVED function immediately after. However, when I run it, it doesn't actually remove the movieclip from the stage. It is still there. When I navigate to a different section ("remote" or "assist") and navigate back to "home", it doesn't fire a second time, everything works properly after the first time.
    So I guess my question is, what would fire the REMOVED_FROM_STAGE event without actually removing the object from the stage? And why would it only happen once?
    Thanks for looking!
    -Nick
    Here is some code as well as a screen shot of my main timeline:
    package src.modules {
        import flash.display.MovieClip;
        import flash.events.Event;
        import flash.events.MouseEvent;
        import src.utils.greensock.TweenLite;
        import src.utils.greensock.easing.*;
        public class ModHome extends MovieClip {
            private static const DISTANCE:int = 700;
            private static const TWEEN_DURATION:Number = 1.0;
            private var _currentPage:int = 1;
            private var _isDone:Boolean = true;
            public function ModHome() {
                super();
    //            trace("home initialized");
                addEventListener(Event.ADDED_TO_STAGE, onAddedToStage, false, 0, true);
            private function onAddedToStage(evt:Event):void {
                trace("home added to stage");
                removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
                addEventListener(Event.REMOVED_FROM_STAGE, onRemovedFromStage, false, 0, true);
                // BUTTONS
                pageLeft_btn.addEventListener(MouseEvent.CLICK, onMouseClick, false, 0, true);
                pageRight_btn.addEventListener(MouseEvent.CLICK, onMouseClick, false, 0, true);
            private function onRemovedFromStage(evt:Event):void {
                removeEventListener(Event.REMOVED_FROM_STAGE, onRemovedFromStage);
                // BUTTONS
                pageLeft_btn.removeEventListener(MouseEvent.CLICK, onMouseClick);
                pageRight_btn.removeEventListener(MouseEvent.CLICK, onMouseClick);
    //            trace("home removed from stage");
            private function onMouseClick(evt:MouseEvent):void {
                if(_isDone) {
                    switch (evt.target.name) {
                        case "pageLeft_btn" :
                            movePages("left");
                            break;
                        case "pageRight_btn" :
                            movePages("right");
                            break;
                        default :
    //                        trace("home -- nothing");
                            break;
            // SCROLLING WINDOW
            private function movePages(thedirection:String):void {
                _isDone = false;
                var x1:int;
                switch (thedirection) {
                    case "right" :
                        if (_currentPage > 1) {
                            _currentPage = _currentPage - 1;
                            x1 = pages_mc.x + DISTANCE;
                            TweenLite.to(pages_mc, TWEEN_DURATION, {x:x1, ease:Quint.easeInOut, onComplete:onTweenComplete});
                        } else {
                            _isDone = true;
                        break;
                    case "left" :
                        if (_currentPage < 3) {
                            _currentPage = _currentPage + 1;
                            x1 = pages_mc.x - DISTANCE;
                            TweenLite.to(pages_mc, TWEEN_DURATION, {x:x1, ease:Quint.easeInOut, onComplete:onTweenComplete});
                        } else {
                            _isDone = true;
                        break;                   
            private function onTweenComplete():void {
                _isDone = true;
                pageMarker_mc.gotoAndStop(_currentPage);
    //            trace("complete");

    No reason in particular, when I created the class, FlashBuilder put it in there (I'm using Flash Pro CS5 + Flash Builder 4). I read that it calls it by default when the class is constructed, so having it in or out didn't really matter. I did comment it out with no luck, but I ended up shifting around the timeline quite a bit today and the problem has gone away. It seemed to only do it when it was in the first frame.
    Thanks for your help, I'm going to investigate it further when I have time just for reference, I'll post anything I find here.
    -Nick

  • Unique constraint fired when updating in MERGE statement.

    Hi guys
    I have an issue which I am unable to resolve. Would appreciate any help on this. The data setup and the scenario is as below.
    SQL*Plus: Release 10.2.0.1.0 - Production on Wed May 4 11:46:02 2011
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP and Data Mining options
    SQL>
    create table table_1
    (id number,
    id_name varchar2(20));
    Alter table table_1 add primary key(id);
    create table table_2
    (id number,
    id_name varchar2(20));
    insert into table_2 values (1, 'id_1');
    insert into table_2 values (2, 'id_2');
    insert into table_2 values (1, 'id_1_upd');
    SQL> select * from table_1;
    no rows selected
    SQL> select * from table_2;
            ID ID_NAME
             1 id_1
             2 id_2
             1 id_1_upd
    SQL>
    SQL>  merge into table_1 target
      2   using (select id,
      3                 id_name
      4            from table_2) source
      5   on (source.id = target.id)
      6   when matched then
      7      update set target.id_name = source.id_name
      8   when not matched then
      9      insert(id,
    10             id_name)
    11      values(source.id,
    12             source.id_name);
    merge into table_1 target
    ERROR at line 1:
    ORA-00001: unique constraint (SYS_C00137508) violated
    SQL> ed
    Wrote file afiedt.buf
      1  select constraint_type, table_name, status
      2*   from user_constraints where constraint_name = 'SYS_C00137508'
    SQL> /
    C TABLE_NAME                     STATUS
    P TABLE_1                        ENABLEDCan someone please help me in resolving this as the actual code that I am developing has the same setup and I am constantly getting this error. So long as the same record does not come up in the "source" table, MERGE does either an update or an insert.
    But as soon a "duplicate" record comes up for updation, I am getting the unique constraint error.
    Thanks
    - K.B.

    Dear,
    ERROR at line 1:
    ORA-00001: unique constraint (SYS_C00137508) violatedYou need to think about two things
    (a) read consistency : what was the situation of table_1 when the maching clause has been initially evaluated ; there were 0 rows matching which means the merge operation will be all insert
    (b) your matching clause has a problem : the join column must be unique in both tables otherwise the merge will be ambigous. You don't have a unique key on the source table
    (c) think that the merge operation will never insert id =1 and then update id = 1 within the same operation. This will never happen
    Hope this helps
    Mohamed Houri

  • OTL Rule firing when deleting the time card

    Hi Friends,
    I have created an OTL Time entry rule and this works fine while entering the time entry. But when I try to delete the complete time card the application fires the same time entry rule.
    Can someone help me as to why this error comes up when I try to delete the time card. Without the time entry rule I am able to delete(end-date) the time card successfully.
    Thanks

    Hi,
    You might have selected the value Submission / Resubmission / Delete to when you created the Time Entry Rule. Select only Submission / Resubmission.

  • Primary key constraint firing when there's no need

    Hi All,
    I've got a very weird problem.
    I've written a PL/SQL procedure to insert addresses into a tabel. The adresses are assigned an unique number by means of a sequence. This unique number is the primary key of the table and has to be unique.
    The following thing occurs: The primary key constraint fires whenever i try to insert a record and i can't figure out why.
    I use the following code
    PROCEDURE mk_adr(klant NUMBER, receiver NUMBER) IS
    oidtje NUMBER DEFAULT 0;
    BEGIN
    BEGIN
    SELECT lea_adr_seq.NEXTVAL INTO oidtje
    FROM dual
    INSERT INTO lea_adr (
    oid, object, streetname,
    housenumber, housealpha, ponumber,
    postcode, cityname, locationdesc,
    province, kind, country_id,
    relation_id, offerrec_id,
    h_trans_van,
    h_geldig_van,
    h_gebruiker
    SELECT oidtje, oidtje, streetname,
    housenumber, housealpha, ponumber,
    postcode, cityname, locationdesc,
    province, kind, country_id,
    null, receiver,
    To_Date('01-01-2000'),
    To_Date('01-01-2000'),
    'conv'
    FROM lea_adr
    WHERE relation_id = klant
    EXCEPTION
    WHEN Others THEN
    conv_algemeen.debugMessage('mk_adr :: '||SQLERRM);
    END;
    END;
    as you can see the very first thing i'm doing is selecting a new unique number into oidtje from the sequence which provides the numbers. Then i use it to insert the record. The insert fails with the primary key constraint firing saying that oid is not filled with an unique number.
    When i do "select max(oid) from lea_adr;" I get a number lower than the number the i get when doing "select lea_adr_seq.nextval from dual;"
    So am i overseeing something or is something very obvious going wrong ?
    Patrick

    Write your procedure like the following and it will work.
    PROCEDURE mk_adr(klant NUMBER, receiver NUMBER) IS
    BEGIN
    INSERT INTO lea_adr (
    oid, object, streetname,
    housenumber, housealpha, ponumber,
    postcode, cityname, locationdesc,
    province, kind, country_id,
    relation_id, offerrec_id,
    h_trans_van,
    h_geldig_van,
    h_gebruiker
    SELECT lea_adr_seq.NEXTVAL, lea_adr_seq.NEXTVAL, streetname,
    housenumber, housealpha, ponumber,
    postcode, cityname, locationdesc,
    province, kind, country_id,
    null, receiver,
    To_Date('01-01-2000'),
    To_Date('01-01-2000'),
    'conv'
    FROM lea_adr
    WHERE relation_id = klant
    EXCEPTION
    WHEN Others THEN
    conv_algemeen.debugMessage('mk_adr :: '||SQLERRM);
    END;
    Using the lea_adr_seq.NEXTVAL more then once in the SAME select will return the same value for both calls.
    SQL> create sequence test
    2 ;
    Sequence created.
    SQL> select test.nextval,test.nextval from dual;
    NEXTVAL NEXTVAL
    1 1
    SQL>

  • My iPhone 3Gs randomly shutting off at any given moment. I could be in the middle of a text, a call, or doing some games and it'll just shut off.  Now here's the unique part. When I go to turn it back on, the apple loading screen pops up but it takes some

    My iPhone 3Gs randomly shutting off at any given moment. I could be in the middle of a text, a call, or doing some games and it'll just shut off.
    Now here's the unique part. When I go to turn it back on, the apple loading screen pops up but it takes somewhere from 3-5 minutes for it to boot up. Then the lock screen with the time and whatnot shows up. From this point on, my iPhone has a chance to shut itself back down and I have to repeat the process over and over again. Most of the time the lock screen flashes and then goes straight to black (shut down) but sometimes I can make it a few menus before it shuts itself down.
    The only way to keep the iPhone on is to plug it into a charger of any sort. I'm fairly certain it isn't a battery charge issue because this happens at any % of power and sometimes my iPhone can use up all of its charge and not have this happen while other times I can be at 90-100% and it could randomly shut itself down. What can I do in this situation if some has some solution to this problem please let me know on [email protected] Thanks!

    Not sure if this Term is Relevant towards an iPhone but, my iPhone won't Post unless if it's plugged into a Charger.

  • HP OfficeJet Pro 8500 goes to sleep, but often wakes up when it shouldn't

    HP OfficeJet Pro 8500 goes to sleep, but often wakes up when it shouldn't.  This happens over and over.  It used to sleep until I sent something to be printed. I now shut the printer down, but that takes a long time to start it up.

     When you finally get around to looking at my post, never mind.
    I reset the factory defaults on the printer and reauthorized my WiFi network.
    Now it is working.

  • Podcasts are syncing when they shouldn't be

    My iPod finally ran out of space so I wanted to remove some of the video podcasts from it. I have my podcast syncing set to sync the selected podcasts so I thought I could just uncheck the ones I didn't want to keep on my iPod and sync to remove them. That didn't work so I put my iPod in manual sync mode and removed them. I turned off the manual sync option and told it to sync again and it's copying all my podcasts (even the ones that aren't checked on the podcast tab). How do I make it stop so I can free up some space?

    Ok, I can confirm that the problem doesn't affect music playlists.
    I've also noticed that the files that get copied when they shouldn't take up more space than the ones that are supposed to be there. I noticed this by syncing, checking a podcast that was previously unchecked, then resyncing. It wasn't a lot of space, only around 10-25 mb.
    I've also found a workaround to get the files off my iPod. I have the "Sync only checked songs and videos" option checked on the summary tab for my iPod in iTunes. I can uncheck each individual podcast that I don't want to be on my iPod, then resync and they are removed. So I guess the problem is only present on the Podcasts (possibly movies and tv shows too) tab of the iPod screen in iTunes.
    Is there somewhere else I should go to submit a bug report?

  • Event Fired when a mxml component is shown on screen

    hello,
    I have following application structure nested up to 2/3 level.
    Application
         linkbar connected to viewstack
         viewstack
              NavigatorContent
                   mxml Component
              NavigatorContent
                   mxml Component
    mxml componet in turn has similar structure
    componet
         linkbar connected to viewstack
         viewstack
              NavigatorContent
                   mxml Component
              NavigatorContent
                   mxml Component
    and end component is form which is shown and actions performed
    I want to execute specific code when the form is first time shown
    which will collect data from server and will show for further actions.
    User will edit/delete/update data with various button clicks.
    I tried activate event on end component but it seems that it wont get
    fired at all. End components are enclosed in BorderContainer or Group.
    To test activate event I have used Alert.show only but popup is not shown
    when I select link button on penutimate linkbar.
    If I am doing something wrong please let me know as well please
    guide me which event shall I use so that whenever linkbutton is
    pressed on linkbar it will fire that event. In that event I can check
    whether it has been called earlier by checking some variable which
    will be null in creation complete and set in event fired when linkbutton is pressed.
    Thanks and regards
    Raja

    I think 'creationComplete' is the closest event to what you are looking for.

  • AfterValueChange event trigged when it shouldn'tbe...

    Hi there,
    I'm hoping that someone out there has experienced the following (and
    knows why it is happening. ) :-)
    I have a couple of windows on which the AfterValueChange event is
    triggered on a field upon hitting the delete key.
    We all know that this should only happen upon leaving the field, ie. the
    field loosing focus. The problem is that I'm trying to recreate this in
    a simple test class, but now it won't happen. I still have the original
    windows on which it is happening, but I would like to construct
    something small and simple to send to Forte.
    Any ideas as to why this could be happening?
    Many thanks in advance.
    Jaco
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    Thanks for the replies so far, but this is not the problem. I know about
    the "Validate on keystroke" option and it is definitely swithed off.
    I was rather thinking along the lines of this being be a 'funny' in
    Forte. Has anyone seen this before? Here is more information:
    1) The windows that it is happening on all have parent windows.
    2) The fields with this problem are all part of a mapped gridfield, ie.
    it has a type.
    However, I have constructed a test class with these characteristics, but
    it is no good. There must be something else that could cause this. Any
    ideas?
    -----Original Message-----
    From: Rottier, Pascal [SMTP:[email protected]]
    Sent: Friday, October 09, 1998 10:53 AM
    To: Fouche, Jaco
    Cc: Forte Users Mailing list
    Subject: RE: AfterValueChange event trigged when it shouldn't be...
    Hi Jaco,
    Check if the option "Validate on keystroke" is set
    to true on the widget that posts the AfterValueChange.
    If so, than that's the reason. Turn it off and your
    problem will go away.
    Pascal
    Hi there,
    I'm hoping that someone out there has experienced the following (and
    knows why it is happening. ) :-)
    I have a couple of windows on which the AfterValueChange event is
    triggered on a field upon hitting the delete key.
    We all know that this should only happen upon leaving the field, ie.
    the
    field loosing focus. The problem is that I'm trying to recreate this
    in
    a simple test class, but now it won't happen. I still have the
    original
    windows on which it is happening, but I would like to construct
    something small and simple to send to Forte.
    Any ideas as to why this could be happening?
    Many thanks in advance.
    Jaco
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive
    <URL:http://pinehurst.sageit.com/listarchive/>
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

  • Can we have triggers that get fired when we Query a table?

    Hi All,
    What could be the pricise answer to the following question?
    1. Can we have triggers that get fired when we Query a table?
    2. What the relation of triggers and delete, truncate statement in one line?
    3. What is data modelling? Why is it necessary?
    4. Which are not mandatory but essential files in Oracle?
    Regards,
    AAK

    1. Can we have triggers that get fired when we Query a table?for INSERT, UPDATE and DELETE statement, yes
    for SELECT statement, no.
    Question 2 is not clear for me.
    Question 3 is very very general ...
    4 >Which are not mandatory but essential files in Oracle?
    all database files (initialization file, control files, datafiles, redo log files) are mandatory. What is not mandatory but considered as a (very) bad practice is
    to have only 1 control file and only 1 redo log group with 1 redo log file.

  • Getting ORA-01403:, when it shouldn't

    Greetings, i apologize beforehand for my spelling, name(takes 6 hours to change) and the headache you migth get, however,
    i bring you the following code, and test results:
    ------Procedure wich throws the error-------
    create or replace
    procedure P_COLEGAS(x in number) as
    ctipo varchar2(20);
    asd varchar2(20);
    cursor curnombre is
    select nombre from unidad,elemento where (elemento.id_elem=unidad.id_elem and unidad.tipo=ctipo and elemento.ciudad=asd);
    begin
    select unidad.tipo, elemento.ciudad into ctipo,asd from unidad,elemento where unidad.id_elem=x and elemento.id_elem=x;
    for blah in curnombre loop
    DBMS_OUTPUT.PUT_LINE('nombre unidad: '||blah.nombre||' ');
    end loop;
    end;
    -what i get when executing the procedure-
    Error que empieza en la línea 1 del comando:
    exec p_colegas(19)
    Informe de error:
    ORA-01403: no data found
    ORA-06512: at "BD00.P_COLEGAS", line 9
    ORA-06512: at line 1
    01403. 00000 - "no data found"
    *Cause:
    *Action:-----------------------------------------------------------
    -----------------the real problem--------------------
    if in that procedure i were to write
    (1)
    select unidad.tipo into ctipo from unidad where unidad.id_elem=x;(2)
    select elemento.ciudad into asd from elemento where elemento.id_elem=x;instead the single query i wrote, we get the following:
    (1) works wonderfull, only gets the error when there are no matches for x.
    (2) throws the error i showed before.
    however when i do the following query in the worksheet and execute it:
    (3)
    select elemento.ciudad from elemento where elemento.id_elem=x;i get what i expected to get 1 row 1 column.(yes it has data)
    note: in (3) the only difference is that i remove the into clause, and x is the same number i used when i execute the procedure.
    --------------------the question------------------------
    why in the procedure, the query (2) fail to fetch the data, the same data wich the query(3) does not fail to fetch?
    i'm getting ORA-01403, when i shouldn't?
    is there a work around to this problem?
    --------------------what i try------------------------------
    nested the query with it's own error handle exception, getting the same results, just catches the error with a different handling.
    tool used: sql developer
    -Example data--
    tested the procedure with the following example data in a brand new workspace getting the same error.
    --  DDL for Table ELEMENTO
      CREATE TABLE "ELEMENTO"
       (     "ID_ELEM" NUMBER,
         "CIUDAD" VARCHAR2(20),
         "TIPO" CHAR(1),
         "X" NUMBER,
         "Y" NUMBER,
         "FECHAHORA_CREACION" TIMESTAMP (6)
    --  DDL for Table UNIDAD
      CREATE TABLE "UNIDAD"
       (     "ID_ELEM" NUMBER,
         "PORCENTAJE_SALUD" NUMBER,
         "NOMBRE" VARCHAR2(20),
         "TIPO" VARCHAR2(20)
    REM INSERTING into ELEMENTO
    SET DEFINE OFF;
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (12,'Infernalia','U',10,10,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (15,'Infernalia','U',10,7,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (19,'Infernalia','U',15,9,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (23,'Infernalia','U',16,8,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (27,'Infernalia','C',15,10,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (52,'Humania','U',26,10,to_timestamp('22-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (58,'Humania','U',24,9,to_timestamp('22-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (62,'Humania','U',27,11,to_timestamp('22-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (64,'Humania','C',25,8,to_timestamp('22-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (78,'GruntVille','U',47,32,to_timestamp('29-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (84,'GruntVille','U',42,28,to_timestamp('29-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (89,'GruntVille','U',43,29,to_timestamp('29-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (91,'GruntVille','C',44,37,to_timestamp('29-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (29,'Infernalia','C',16,7,to_timestamp('12-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    Insert into ELEMENTO (ID_ELEM,CIUDAD,TIPO,X,Y,FECHAHORA_CREACION) values (90,'GruntVille','U',49,36,to_timestamp('29-NOV-20 12.00.00.000000000 PM','DD-MON-RR HH.MI.SS.FF AM'));
    REM INSERTING into UNIDAD
    SET DEFINE OFF;
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (12,100,'Grang','Soldado');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (15,100,'Krout','Médico');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (19,100,'Warf','Obrero');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (23,100,'Puaj','Obrero');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (52,100,'Marcelus','Soldado');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (58,100,'Claudius','Soldado');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (62,100,'Arturius','Obrero');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (78,100,'Klaknot','Médico');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (84,100,'Staisht','Médico');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (89,100,'Bjorkson','Soldado');
    Insert into UNIDAD (ID_ELEM,PORCENTAJE_SALUD,NOMBRE,TIPO) values (90,100,'Sknot','Médico');
    --  Constraints for Table ELEMENTO
      ALTER TABLE "ELEMENTO" ADD CONSTRAINT "ELEMENTO_CHK1_TIPO" CHECK (TIPO IN ('U', 'C')) ENABLE;
      ALTER TABLE "ELEMENTO" ADD CONSTRAINT "ELEMENTO_PK" PRIMARY KEY ("ID_ELEM") ENABLE;
      ALTER TABLE "ELEMENTO" MODIFY ("ID_ELEM" NOT NULL ENABLE);
      ALTER TABLE "ELEMENTO" MODIFY ("CIUDAD" NOT NULL ENABLE);
      ALTER TABLE "ELEMENTO" MODIFY ("TIPO" NOT NULL ENABLE);
      ALTER TABLE "ELEMENTO" MODIFY ("X" NOT NULL ENABLE);
      ALTER TABLE "ELEMENTO" MODIFY ("Y" NOT NULL ENABLE);
      ALTER TABLE "ELEMENTO" MODIFY ("FECHAHORA_CREACION" NOT NULL ENABLE);
    --  Constraints for Table UNIDAD
      ALTER TABLE "UNIDAD" MODIFY ("ID_ELEM" NOT NULL ENABLE);
      ALTER TABLE "UNIDAD" MODIFY ("PORCENTAJE_SALUD" NOT NULL ENABLE);
      ALTER TABLE "UNIDAD" MODIFY ("NOMBRE" NOT NULL ENABLE);
      ALTER TABLE "UNIDAD" MODIFY ("TIPO" NOT NULL ENABLE);
      ALTER TABLE "UNIDAD" ADD CONSTRAINT "UNIDAD_PK" PRIMARY KEY ("ID_ELEM") ENABLE;
    --  Ref Constraints for Table ELEMENTO
    --  Ref Constraints for Table UNIDAD
      ALTER TABLE "UNIDAD" ADD CONSTRAINT "UNIDAD_ELEMENTO_FK1" FOREIGN KEY ("ID_ELEM")
           REFERENCES "ELEMENTO" ("ID_ELEM") ENABLE;
    /Edited by: 975362 on 06-12-2012 04:47 AM
    Edited by: BluShadow on 06-Dec-2012 12:51
    added {noformat}{noformat} tags for readability of code/data.  Please read {message:id=9360002} and learn to do this yourself in future.
    Edited by: 975362 on 06-12-2012 05:44 AM
    added example data.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Oops, I mi9ssed table ELEMENTO has column X. When you use:
    where unidad.id_elem=x and elemento.id_elem=x;column names take precedence over PL/SQL variables wnd X is resolved as table ELEMENTO column X. not as PL/SQL procedure parameter X. Change PL/SQL procedure parameter name:
    SQL> create or replace
      2  procedure P_COLEGAS(x in number) as
      3  ctipo varchar2(20);
      4  asd varchar2(20);
      5  
      6  cursor curnombre is
      7  select nombre from unidad,elemento where (elemento.id_elem=unidad.id_elem and unidad.tipo=ctipo
    and elemento.ciudad=asd);
      8  
      9  begin
    10  select unidad.tipo, elemento.ciudad into ctipo,asd from unidad,elemento where unidad.id_elem=x
    and elemento.id_elem=x;
    11  for blah in curnombre loop
    12  DBMS_OUTPUT.PUT_LINE('nombre unidad: '||blah.nombre||' ');
    13  end loop;
    14  end;
    15  /
    Procedure created.
    SQL> exec p_colegas(19)
    BEGIN p_colegas(19); END;
    ERROR at line 1:
    ORA-01403: no data found
    ORA-06512: at "SCOTT.P_COLEGAS", line 9
    ORA-06512: at line 1
    SQL> create or replace
      2  procedure P_COLEGAS(p_x in number) as
      3  ctipo varchar2(20);
      4  asd varchar2(20);
      5  
      6  cursor curnombre is
      7  select nombre from unidad,elemento where (elemento.id_elem=unidad.id_elem and unidad.tipo=ctipo
    and elemento.ciudad=asd);
      8  
      9  begin
    10  select unidad.tipo, elemento.ciudad into ctipo,asd from unidad,elemento where unidad.id_elem=p_
    x and elemento.id_elem=p_x;
    11  for blah in curnombre loop
    12  DBMS_OUTPUT.PUT_LINE('nombre unidad: '||blah.nombre||' ');
    13  end loop;
    14  end;
    15  /
    Procedure created.
    SQL> exec p_colegas(19)
    PL/SQL procedure successfully completed.
    SQL> SY.

  • Phone rings when it shouldn't

    I put my phone on vibrate but it will ring when I get a call. It was not one of my contacts either.

    I figured out the HTMLDB problem. The process executes conditionally based on the Value of the submitted buton, NOT the name of the submitted button. So I had a button in another region that had a different name, but had the same Value. (ie. "Go), so the process was executing when it shouldn't have been. This is a bug.

  • Outlook 2013 Rules issue when more than 50 rules exist ("The rules on this computer do not match the rules on Microsoft Exchange").

    I think I may have found a bug.
    My Outlook 2013 profile has more than 75 rules. When I started testing Outlook 2013, I got the message "The rules on this computer do not match the rules on Microsoft Exchange. Only one set of rules can be kept. You will usually want to keep the rules
    on the server. Which rules do you want to keep?"
    I did the following troubleshooting:
    1. I created a new Outlook profile. This didn't fix the issue.
    2. I exported my rules, cleared them using "outlook /cleanrules", then reimported the rules. This didn't fix the issue.
    3. I cleared the rules again (outlook /cleanrules), then hand-entered the rules. This also didn't fix the issue.
    4. I reduced the number of rules to less than 50. This FIXED the problem.
    5. When I entered rule #51, the problem came back. When I removed ruled #51, the problem was again fixed.
    Does anyone know of a fix or workaround to this issue?
    Thanks.

    Sounds like you went over your "rule quota limit" as you do have a great number of rules.  Please see the link below for cause and possible resolution.
    http://support.microsoft.com/kb/886616
    Be kind and Mark as Answer if I helped.

  • Which event will be fired when I after set JFrame.setVisible(false)

    Experts.
    I want to know which event will be fired when I after set JFrame.setVisible(false)?
    Because I need to check a thread is finished it job or not.
    I have checked windowClosing event, but it doesn't work.
    Thanks
    Francis

    Oh....
    Sorry, I find it will fired on componentHidden event.
    Very sorry.

Maybe you are looking for