Get error when using IF - ELSE in a LOV condition...

Hi all

I have a Table of name TEST with columns - PROJECT MANAGER, PERSON, as shown below.

HEAD of PROJECT PERSON
ABC PR_A YES
DEF PR_B
XYZ PR_C YES

(Please read the table above as - PR_A as a PROJECT;) ABC as a PERSON and the entry 'YES' for the Manager column.)

The requirement is that the present entries in the column of the PERSON must be indicated as a LOV as far as the conditions are met.

I have two elements on the page -: PItem1 and: PItem2



IF: PItem1 = 'Remove' and THEN

RETURN

SELECT PERSON d, PERSON r
of the TEST
WHERE the project =: PItem2 AND MANAGER = "YES".
ORDER BY 1;

ON THE OTHER
RETURN

SELECT PERSON d, PERSON r
of the TEST
WHERE of the = PROJECT: PItem2
ORDER BY 1;

END IF;



But when I run this code, I get an error like - ORA-00900: invalid SQL statement


Please help me fix...



Thank you and best regards,
Suhas

:)

SELECT   person d, person r
    FROM TEST
   WHERE project = :pitem2
     AND NVL (manager, 'NO') =
                  CASE
                     WHEN :pitem1 = 'Deletion'
                        THEN 'YES'
                     ELSE NVL (manager, 'NO')
                  END
ORDER BY 1;

Denes Kubicek
-------------------------------------------------------------------
http://deneskubicek.blogspot.com/
http://www.Apress.com/9781430235125
http://Apex.Oracle.com/pls/Apex/f?p=31517:1
http://www.Amazon.de/Oracle-Apex-XE-Praxis/DP/3826655494
-------------------------------------------------------------------

Tags: Database

Similar Questions

  • Get error when using charles

    Hi all

    I learn the FCS and when I use Charles to see what is happening in the transactions, I get errors:

    #THROWING ERROR # URLLoader onError. Error. : [IOErrorEvent type = "ioError" bubbles = false cancelable = false eventPhase = 2 text = "Error #2032: stream error."] ["URL: http://connectnow.acrobat.com/XXXX/room2?glt=g%3A & x = 0% 2E6759106982499361 & mode = xml'] >
    INVALID_INSTANCE: Invalid Instance
    at com.adobe.rtc.session.managers::SessionManagerBase/receiveError() [C:\work\main\connect\co comoPlayer10\src\com\adobe\rtc\session\managers\SessionManagerBase.as:270]
    at com.adobe.rtc.session.managers::SessionManagerFMS/receiveError() [C:\work\main\connect\coc omoPlayer10\src\com\adobe\rtc\session\managers\SessionManagerFMS.as:288]
    at com.adobe.rtc.session.managers::SessionManagerAdobeHostedServices/receiveError() [C:\work\ main\connect\cocomoPlayer10\src\com\adobe\rtc\session\managers\SessionManagerAdobeHostedSe rvices.as:254]
    at com.adobe.rtc.session.managers::SessionManagerAdobeHostedServices/onMeetingError() [C:\wor k\main\connect\cocomoPlayer10\src\com\adobe\rtc\session\managers\SessionManagerAdobeHosted Services.as:93]
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at com.adobe.rtc.session.sessionClasses::MeetingInfoService/onError() [C:\work\main\connect\c ocomoPlayer10\src\com\adobe\rtc\session\sessionClasses\MeetingInfoService.as:347]
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at flash.net::URLLoader/onComplete()


    Everyone gets these errors, and if so what do you use instead of Charles?

    Thank you

    timgerr

    Charles generates it is on certificates for each site. That's why you have put in custody and other issues during the test content on SSL w / Charles. The developer has addressed this issue by creating certificates for each browser to accept the certificate of Charles. It cannot solve the problems in the original post, but it will be ceartinly resolution of issues tests sites over SSL w / Charles in general. Refer to the directions below from the Director:

    http://www.charlesproxy.com/documentation/using-Charles/SSL-certificates/

  • Get error when using apache

    So I'm under Mac El Capitan. I used to be able to use the Apache web server on the mac in the same operating system but how ever when I'm recently trying to use appache I get this error

    httpd: syntax error on line 66 of the /private/etc/apache2/httpd.conf: cannot load libexec/apache2/mod_authn_file.so into server: dlopen (/ utilisateurs/keeffefamily/Sites/libexec/apache2/mod_authn_file.so, 10): image not found

    And when I try to start, it seems as if it worked, but when I go to http://localhost/ nothing loads to the top

    Data sheet:

    2.9 GHz Intel Core i5

    8 GB 1600 MHz DDR3

    OS X El Capitan 10.11.1

    NVIDIA GeForce GT 750M 1024Mo

    Syntax error at line 66 of the /private/etc/apache2/httpd.conf

    What is this line?

  • Get errors when using the xml parsers in my client application.

    Hello

    I use JDE 4.5.0, Jdk 1.6.  In my application, I need to read the xml data so I used the packages below

    import java.io.File;
    Import javax.xml.parsers.DocumentBuilder;
    Import javax.xml.parsers.DocumentBuilderFactory;
    to import org.W3C.DOM.document;
    Import org.w3c.dom.Element;
    Import org.w3c.dom.Node;
    Import org.w3c.dom.NodeList;

    But when compiling it's show

    Cannot resolve symbol
    symbol: DocumentBuilderFactory class
    location: packet analyzers
    Import javax.xml.parsers.DocumentBuilderFactory;

    Cannot resolve symbol
    symbol: class file
    Location: package io
    import java.io.File; ...............

    Same type of java file that uses similar packages is correctly compile another IDE (Editplus). That's why show this compilation errors.  I scoured the forums of Sun they mentioned that "XML support is build in the JVM 1.4 and later." No need of extra pots.  How do I set this compilation errors.

    Please give your suggestion, thanks for the tip for the same thing.

    Kind regards

    Sunil.G

    Thanks for your reply MSohm.

    In my class used resulting classes that the errors below.

    Import javax.xml.parsers.DocumentBuilder;

    Import javax.xml.parsers.DocumentBuilderFactory;

    now instead of what I used

    Import net.rim.device.api.xml.parsers.DocumentBuilder;
    Import net.rim.device.api.xml.parsers.DocumentBuilderFactory;

    reading file, I use (instead of java.io.File)

    InputStream inputStream is getClass () .getResourceAsStream (_xmlFileName);.
    Doc document = db.parse (inputStream);

  • Get errors when using web packaging services

    I use linux server and get following errors in the present .epub or file.pdf.

    " < error xmlns =" ' http://ns.adobe.com/adept ' data = "E_PACK_FILE_READ " http://myserverurl/packaging/package test.pdf test.pdf%20(No%20such%20file%20or%20directory) "/ > "

    I have stated my case. I have two servers you have tomcat with acs services upward and running and others is based php server where I call this service pakaging. I kept the file unencrypted Server php based from script to script.

    do we need to keet the file unencripted on the server that have services acs?

    ..............

    Mathe

    The problem will be to 32K in size, channels should be divided into pieces separated from 32K for serialization purposes.  While the code PHP is it doing it does not include the extra string tag in each segment.  I suggest to use the element of dataPath rather avoided.  (ps I have connected the bug internally)

  • Windows Update lists an important update, but I get error when downloading it. "Fix" suggested did not work.

    Windows Update lists an important update, but I get error when downloading it.  I ran update readiness tool and two logs in Windows\logs appear no error at all and nothing fixed.  The update that will not download is KB974332, which can solve some problems I encounter.  What else can be done, or should I ignore this update?
    Just upgraded to Win7 64-bit, Vista 64 - bit Edition Ultimate Home premium.

    Hello

    Welcome to the Microsoft Vista answers Forum!

    We would like to ask you some questions to help us focus on the right place.

    (a) what is the error that you receive on the computer?

    (b) since when you are facing this problem?

    You can try the steps below and check if the problem is resolved.

    Note: this problem may occur if some of the windows update components are corrupt, so we will try to reset the windows update components and look for the number.

    You must follow the link provided below to run the fixit which will automatically fix the problem if you find problems with the fixit, then you can follow the procedure to manually reset Windows component update.

    How to reset the Windows Update components?

    http://support.Microsoft.com/default.aspx/KB/971058

    Also, visit the following link for more reference on the particular update.

    http://support.Microsoft.com/kb/974332

    Hope this information is useful.

    Thank you, and in what concerns:

    Suresh Kumar-Microsoft Support.

    Visit our http://social.answers.microsoft.com/Forums/en-US/answersfeedback/threads/ Microsoft answers feedback Forum and let us know what you think.

  • Add a printer on a vista laptop on. Canon pixma ip3600 Office xp wireless worked until the laptop stops. now get error when you try to connect to it.

    computer Vista laptop does not connect to destop printer

    Add a printer on a computer laptop port local \\computer\printer) on the computer vista laptop. (for xp wireless canon pixma ip3600 Office worked until computer laptop shutdown. now get error when trying to connect.) How to install printer permanent on laptop?

    Hello

    1. What is the exact error message you get?

    I suggest you to refer to this link and check if it helps:

    http://Windows.Microsoft.com/en-us/Windows-Vista/troubleshoot-network-printer-problems

    It will be useful.

  • dbms_crypto - avoid error when using different key in lower environment

    Hello Experts,

    We use Oracle 11.2.0.2. We intend to implement dbms_crypto to encrypt some columns. Clone us the production data at the lower environment (DEV, QC).

    The lowest environments, we do not want to obtain the sensitive data from production and do not plan to use the same key. Instead of getting an error when using different keys, is it possible to get a different set of results.

    In other words, we want the implementation will be same in environments but use a different key in lower environment and obtain different results (or garbage).

    Any suggestions would be greatly appreciated.

    The test of this logic, I get following error when using the different keys to decrypt. It works fine if I use the same key.
    Error on line 1
    ORA-28817: PL/SQL function has returned an error.
    ORA-06512: at "SYS." DBMS_CRYPTO_FFI', line 67
    ORA-06512: at "SYS." DBMS_CRYPTO", line 44
    ORA-06512: at line 19
    DECLARE
      l_credit_card_no    VARCHAR2(19) := '1234 5678 9012 3456';
      l_ccn_raw           RAW(128) := UTL_RAW.cast_to_raw(l_credit_card_no);
     
     l_key               RAW(128) := UTL_RAW.cast_to_raw('abcdefgh');
       l2_key               RAW(128) := UTL_RAW.cast_to_raw('12345678');
    
      l_encrypted_raw     RAW(2048);
      l_decrypted_raw     RAW(2048);
    BEGIN
      DBMS_OUTPUT.put_line('Original  : ' || l_credit_card_no);
    
      l_encrypted_raw := DBMS_CRYPTO.encrypt(src => l_ccn_raw, 
                                             typ => DBMS_CRYPTO.des_cbc_pkcs5, 
                                             key => l_key);
    
      DBMS_OUTPUT.put_line('Encrypted : ' || RAWTOHEX(UTL_RAW.cast_to_raw(l_encrypted_raw)));
    
      l_decrypted_raw := DBMS_CRYPTO.decrypt(src => l_encrypted_raw, 
                                             typ => DBMS_CRYPTO.des_cbc_pkcs5, 
                                             key => l2_key); --**Using different key to decrypt
    
      DBMS_OUTPUT.put_line('Decrypted : ' || UTL_RAW.cast_to_varchar2(l_decrypted_raw));
    END;
    Thank you.

    In general, you can't get different results in different environments, no.

    Of course, you could write your routine to decrypt so that it intercepts it and returns a random string of RAW.

    However, this is not normally the way people go on hiding sensitive data in environments below. It would be much more common to use a tool that is designed for this tool. For example, Oracle has a Pack of masking of data for Enterprise Manager that allows to replace sensitive data with false, but realistic data as part of the updating of the environments below. There are also data from third-party tools like masqueur datamasking.

    Justin

  • get error when you try to lower the java load error 1-4 of 4 0 x 80070643.

    get error when you try to lower the java load error 1-4 of 4 0 x 80070643.

    This forum is for Microsoft Security Essentials.

    You question is with Oracle Java.

    It is recommended to go to www.oracle.com to get help.

  • Receive the 25 (Null) error when using Flightsimulator FSX

    Receive the 25 (Null) error when using Flightsimulator FSX

    Hello

    Try to open the it to start - all programs - Games - Games Explorer, and then clicking the icon FSX.

    A disk error of 25 means that the program cannot read your disk reading.  Either the disc is scratch, dirty or defective.  If you need another drive, or you can try it on another computer. The message of Visual elements of Vista is not serious.  Vista will automatically your screen to a basic compatible mode when the application is launched.  However, it seems that your game is a failure due to the disk error and not the Vista display problem. Try to clean the disc and see if that helps.

    Last resort, it seems you'd have to do a complete uninstall and reinstall FSX.

    Cheers!

  • Get the error when using the UTL_SMTP function in Oracle 11 g

    Hello

    I get the error when executing a trigger e-mail code in oracle 11 g:

    I have following trigger on the temporary table:

    CREATE OR REPLACE TRIGGER temp_temp_message AFTER

    INSERT OR UPDATE ON temp_message FOR EACH LINE

    declare

    Conn UTL_SMTP . CONNECTION ;

    msg VARCHAR2 (2000);

    Start

    Conn := UTL_SMTP . open_connection ( host => '10.250.1.149', port=>25 );

    UTL_SMTP . HELO ( conn, '10.250.1.149');

    UTL_SMTP . mail ( conn, '[email protected]');

    UTL_SMTP . RCPT () conn ' [email protected]');

    msg := "Hello, this is test mail." ;

    UTL_SMTP .data( conn, msg);

    UTL_SMTP . quit smoking ( conn );

    exception when others then

    dbms_output.put_line (sqlerrm);

    raise_application_error (-20000,

    "Failed to send because of the following error messages: ' " || sqlerrm);

    end;

    Insert in temp_message values ()1

    );

    When I insert the record in the table there are given the following error.

    ORA-20000: failed to send messages because of the following error: ORA-24247: access denied by access control (ACL) of network list

    ORA-06512: at the 'APPS '. TEMP_TEMP_MESSAGE', line 14

    ORA-04088: error during execution of trigger ' APPS. TEMP_TEMP_MESSAGE'

    But if I run the next plsql through sqlplus send mail successfully:

    declare

    Conn UTL_SMTP . CONNECTION ;

    MSG VARCHAR2 (2000);

    Start

    Conn := UTL_SMTP . open_connection ( host => '10.250.1.149', port=>25 );

    UTL_SMTP . HELO ( conn, '10.250.1.149');

    UTL_SMTP . mail ( conn, '[email protected]');

    UTL_SMTP . RCPT () conn ' [email protected]');

    msg := "Hello, this is test mail." ;

    UTL_SMTP .data( conn, msg);

    UTL_SMTP . quit smoking ( conn );

    exception when others then

    dbms_output.put_line (sqlerrm);

    raise_application_error (-20000,

    "Failed to send because of the following error messages: ' " || sqlerrm);

    end;

    Thanks in advance.

    Yoann

    To resolve ORA-24247 you must:

    (1) create an acl (if it is not already created)

    (2) add the user privileges using the resources of the network

    (3) to use the ACL to a specific address

    This might be useful

    How to fix an ORA-24247: access denied by access control (ACL) of network list | DB tips

  • Moved to the new server and updated applications upgraded to the APEX, 4.2.6.00.03 and get the random error when using IE 11.

    Hello

    I just moved a set of applications on a new server running Oracle 12 c and APEX 4.2.6.00.03, applications where initially on Oracle 10 G database with APEX 3.2.

    When you access via IE 11 users receive the error message after, when it appears that the only way to clear it is to close IE and reopen the application.

    apex_error.PNG

    There is an application that uses a database to MYSQL link, but the error when you use applications that do not use the link, so I'm not sure how to solve the problem.

    The error does not appear when you access applications through Chrome, but not all users have installed chrome.

    Thank you

    Ronnie

    Well Ronnie,

    This thread suppose to have a problem like yours and resolved. Please try on your side:

    After the footer I use: dbms_session.close_database_link ('mysql_databaselink_name');

    Please Urgent help on ora_sqlcode :-28500

    It will be useful.

    Thank you

    Sunil Bhatia

  • Tecra 8100 system error when using Bank B

    Hello

    I get Bluscreens and system errors when you use Bank B. When you use Module1 in the Bank, everything is ok. When the same module as Bank A Bank (Bank A + B) b, I get errors.

    So, what would it be? What I have to 'turn on' the use of BANK B anywhere or not it looks like its defekt?

    Thanks for any help

    Hello

    Well, you must replace the motherboard if the memory bank has a defect. In this case, the only good way to connect with the service partner. They might give you detailed information.

    Good bye

  • Unknown error when using Vision USB3 with PixeLink D725CU-T

    Hello

    I recently bought a camera PixeLINK PL-D725CU-T to use with LabVIEW. The camera is a camera USB 3.0 and meets the standard USB3.0 Vision according to the here AIA Web site: http://www.visiononline.org/product-catalog-detail.cfm?productid=4196.

    Unfortunately, when I try to set the camera using the Acquisition of Vision of NOR-IMAQdx USB3.0 drivers and run the camera in MAX I get error unknown 0xBFF6903B. I have a vision capture program I wrote in LabVIEW 2016-64-bit as well as survey the same mistake (I PSS and have everything updated versions latest software as part of my troubleshooting).

    The camera works through DirectShow in MAX interface and my LabVIEW program suggesting an incompatibility with the current IMAQdx driver. I have read a few previous posts on the update of the firmware on the cameras and am currently in contact with the manufacturer to try to resolve the problem on this end as well. Is there a way to revert to an earlier version of the Acquisition of the Vision to see if a previous version worked? Or I am barking the wrong tree here?

    I am running Windows 7 64 bit system. I have versions of LabVIEW installed 32-bit and 64-bit 2016.

    Any help is appreciated.

    Thank you.

    This problem has been resolved with an update of the firmware of PixeLINK so the patch you mentioned that was provided by OR support and support PixeLINK.

  • Get errors when you try to activate Windows 2008 Standard Server

    I upgraded my server from Windows 2000 to Windows 2008. When I try to activate Windows, I have the error first:

    Activation error: Code 0x8007232b
    DNS name does not exist
    So find kbase ID of Article: 929826
     
    Tried to load my product key again from the command prompt:

    slmgr - ipk
     
    Now I get error:
    0xC004C003 error code
     
    the activation server determined that the specified product key is in use

    This forum is not compatible Windows Server, you need to create a new post on the TechNet forums for assistance: http://social.technet.microsoft.com/Forums/en-US/winservergen/threads

Maybe you are looking for

  • HP 15-G009AX: BLUETOOTH DOES NOT

  • Satellite A215-S7444 - freezes after Hibernation mode

    I have a Satellite A215-S7444 which is 2 years. It came with a 32-bit version of Vista. I just do a custom install of Windows7 64 bit. It seems that after coming out of standby the laptop hangs and I have to do a hard reboot. Any suggestions would be

  • I need drivers for a HP Pavilion DV2120us

    I recently did a clean installation of Windows XP and I encounter a difficulty finding all the right drivers for my HP Pavilion DV2120us. I have tried every single driver available on the HP site which is available for this particular model. I don't

  • GPIB-ENET 21 error code

  • Profile sRGB 2713HM

    Hi, im doing mainly 3d/Animation/images edition for the web and television. Should I work on the profile instead of the standard sRGB when the suite using adobe? Should I put in place also in all adobe applications the sRGB profile in color managemen