Exception handler does not work

Hi guys,.
My feature works very well when the input of user name and password are correct. I'm trying to understand why my exception handler does not display the contents of the DBMS_OUTPUT. Put_line when the user name or password are not correct. Any ideas?
Thank you
Carpet


G_output VARIABLE VARCHAR2 (30)
G_username VARIABLE VARCHAR2 (8)
G_password VARIABLE VARCHAR2 (8)
G_ck VARIABLE CHAR


BEGIN
: g_username: = 'gma1;
: g_password: = 'Michael ';
: g_ck: = 'n';
END;
/


CREATE OR REPLACE PACKAGE login_pkg
FUNCTION log_in_pf
(p_username IN VARCHAR2,
p_password IN VARCHAR2,
p_ck IN OUT the TANK)
RETURN OF CHAR;
END;
/


CREATE OR REPLACE PACKAGE BODY login_pkg
FUNCTION log_in_pf
(p_username IN VARCHAR2,
p_password IN VARCHAR2,
p_ck IN OUT the TANK)
RETURN OF TANK
IS
lv_username_txt bb_shopper.username % TYPE;
lv_password_txt bb_shopper.password%TYPE;
BEGIN
SELECT username, password
IN lv_username_txt, lv_password_txt
OF bb_shopper
WHERE username = p_username
AND password = p_password;
IF lv_username_txt | lv_password_txt = p_username | p_password THEN
p_ck: = 'Y ';
ANOTHER p_ck: = 'n';
END IF;
RETURN p_ck;
EXCEPTION
WHEN NO_DATA_FOUND THEN
DBMS_OUTPUT. Put_line ('Invalid username or password');
END log_in_pf;
END;
/




BEGIN
: g_output: = login_pkg.log_in_pf (: g_username,: g_password,: g_ck);
END;
/

BEGIN
*
ERROR on line 1:
ORA-06503: PL/SQL: function returned no value
ORA-06512: at "SCOTT. LOGIN_PKG', line 23
ORA-06512: at line 2

Published by: Mathew2 on July 20, 2009 03:20

Maybe: In SQL * more set serveroutput on

Published by: jurgenk on July 20, 2009 03:58

Tags: Database

Similar Questions

  • The onDeactivate event handler does not work in InDesign CC. Why?

    Hi guys.

    I'm working on a script in Javascript for InDesign CC.

    The big problem is that the onDeactivate event handler does not work.

    Here is an example that works in InDesign CSx, but not in InDesign CC:

    #target indesign
    var w = new Window ("dialog", "Test onDeactivate");
    var et_1 = w.add("edittext", [undefined, undefined, 300, 30], "Lorem ipsum");
    var et_2 = w.add("edittext", [undefined, undefined, 300, 30], "Dolor sit amet");
    var st = w.add("statictext", [undefined, undefined, 300, 30], "CONSOLE:\r\r", {multiline: true});
    et_1.onDeactivate = et_2.onDeactivate = function(){
         st.text = "CONSOLE: I left the field with this text:\r\t«" + this.text +"»"; }
    var b_ok = w.add("button", undefined, "OK");
    w.show();
    

    The script displays a dialog with text edit fields window 2: when a field loses focus (by clicking on the other), the "CONSOLE" shows the text of the old domain.

    Adobe, please, solve this problem as soon as possible.

    Thank you.

    Giorgio

    This is a bug, and it has been reported. Please report it to yourself, more the better reports. It's no good Adobe invite you in this forum to fix something.

    Peter

  • EXCEPTIONAL CODE does not work... Help, please

    Hye all the...

    I have a code through which I can pick up on WHEN BUTTON PRESSED after selecting an option in the radio group... Code is very well...
    but some time the data resulting is the value null in the table and he goes to an empty table... Here is the code
    declare
    a varchar2 (20);
    Start
    If: result. RadioGroup = 'enrolid' then
    a: = 'enrol_id =' |: result. Search;
    set_block_property('student_result',default_where,a);
    go_block ('student_result');
    execute_query;
    elsif: result.radiogroup = 'semesterid' then
    a: = 'semester_id =' |: result. Search;
    set_block_property('student_result',default_where,a);
    go_block ('student_result');
    execute_query;
    elsif: result.radiogroup = 'courseid' then
    a: = 'course_id =' |: result. Search;
    set_block_property('student_result',default_where,a);
    go_block ('student_result');
    execute_query;
    elsif: result.radiogroup = 'gpa' then
    a: = 'gpa =' |: result. Search;
    set_block_property('student_result',default_where,a);
    go_block ('student_result');
    execute_query;
    elsif: result.radiogroup = 'status' and then
    a: =' status =' | "'|: result.search | ''';
    set_block_property('student_result',default_where,a);
    go_block ('student_result');
    execute_query;
    end if;

    exception
    When no_data_found then
    message ('INVALID FORMATE or NO DATA FOUND');
    message ('INVALID FORMATE or NO DATA FOUND');
    end;


    I WANT to have some sort of MESSAGE that appears what query do cause no selected lines... I use the correct exception?

    Welcome to the Oracle Forums. Please take a few minutes to review the following:


    Following these simple guidelines will ensure a positive experience in any forum; not just this one! ;-)

    It has been my experience that when you use the built-in function Execute_Query the NO_DATA_FOUND exception is handled at the error - released level rather than the local exception handler. If you run a SQL statement in a trigger, then local exception handler will catch the exception - if you have a. Check your form/block-Error trigger level and add a handler for the ORA-01403 or FRM-40735 errors and display your message here.

    Hope this helps,
    Craig B-)

    If someone useful or appropriate, please mark accordingly.

  • Desktop icons can be seen on the desktop, folders are not able to be open, content is not visible; File save option does not work!

    Recently, I tried to re - install samsung smarthru mfp program (already installed and working except the scan).

    at the end of the reinstall the Office is empty, desktop wallpaper and all records of icons could not be seen, I wasn't able to use windows Explorer.

    I tried restoring the system, but even after that the message that the restore system was not made completely.

    Now the problems are that (1) folders/icons on the desktop are not displayed on the desktop (I have added Office to taskbar and all office files can be accessed from there.

    (2) the big problem is that folder except option does not work: cannot save Web pages, also the documents/files are not able to be saved after having published a new name.

    (3) new folder names the names of the files are not created.

    I tried norton internet security 2010 full scan, there is no virus.

    kindly help

    Thank you

    Norton will be interefe with system restore.

    Read this info for problems with the system restore:

    http://Service1.Symantec.com/support/sharedtech.nsf/pfdocs/2005113009323013

    1. If you use Norton (Etc), disable it before using System Restore. info at the link above.

    2. try SR in safe mode:

    Try typing F8 at startup and in the list of Boot selections, select Mode safe using ARROW top to go there > and then press ENTER.

    Try a restore of the system once, to choose a Restore Point prior to your problem...

    Click Start > programs > Accessories > system tools > system restore > choose another time > next > etc.

    3 Malware will stop at the system restore:

    If necessary, do all the workSafe Mode with network.

     

    To get intoSafe Mode with network, press F8 at the Power On / boot and use key arrow upward to get intoSafeMode with networking from the list of options, and then press ENTER.

    http://www.Malwarebytes.org/MBAM.php

    Malwarebytes is as its name suggests, a Malware Remover!

    Download the free Version from the link above.

    Download, install, upgrade and scan once a fortnight.

    See you soon.

    Mick Murphy - Microsoft partner

  • IPhone 6s - microphone does not work on all applications except camera and calls

    Hey, I don't know exactly know what happened with my phone. Suddenly, my microphone work on LINE, Whatsapp and almost all other applications that use mic. Except, camera and when someone call me on my number.

    But it does not work on whatsapp and LINE calls. And it also does not work when I snapchat. Only works on the default camera Apps and call through my number.

    I tried:

    -restart my phone

    -hard reset and blink? Reset with the power and the "home" button.

    -read the micro support page. Still no solution.

    TL; Dr:

    my microphone does not work on every apps on my phone except calls through number and approx. of default camera it gives you just that silence when I play it on voice notes. But it works when I record yourself using videos on the default camera app.

    Hello Bllacke,

    Thank you for using communities of Apple Support.

    I see from your post, some applications have a problem to access your Microphone. I know how it is important to ensure that your applications have access to the Microphone and can use this feature. I have a few things I want to try.

    First, tap Settings on your iPhone and then scroll to the last section that lists your apps. Select the applications that use the microphone and make sure that the Microphone is activated (green).

    Then, follow the steps in the article below to close these applications:

    Force a nearby application on your iPhone, iPad or iPod touch

    Then, test the microphone in these applications again and see if it works.

    Best regards.

  • Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game. __Keyboard is very good

    Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game.
    Keyboard is fine.  Is this a compatibility issue?

    ---------------

  • I have rebuilt my laptop Gateway MX6625, did not drive recovery, is went to the gateway web site, all the drivers have worked except the multimedia sound. The gateway was no help, they told her, but the there does not work

    I have rebuilt my laptop Gateway MX6625, did not drive recovery, is went to the gateway web site, all the drivers have worked except the multimedia sound. The gateway was no help, they told her, but the there does not work

    Hello JesusVigo,

    Thank you for visiting the Microsoft answers community.

    Have you tried to use the disk of Windows XP, or Windows Update running default drivers to search for best driver for your sound card?

    Also, I found only 1 driver on your system gateway Web site is located here.

    Hope this helps Chris.H
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • Does not work IF liquid and EXCEPT in modules/content holders?

    I have the following code of liquid in a model:

    {% case item.zoneId %}

    {% When it is '13435' %}}

    {% assign wholesaler = "True" %}

    {% When it is '51' %}}

    {% assign customer = "True" %}

    {% endcase %}

    Then, I have the following liquid:

    {% If China is 'True' %}

    < p > the text to display for large area secure. < /p >

    {% endif %}

    {% except wholesaler is 'True' %}

    < p > text for all the world. < /p >

    {% endunless %}

    The above code works fine if it is inserted in a page. If I insert the code into a door content and/or layout (in my case the big presentation of product) it does not work.

    I guess that this is simply a limitation currently, but I thought I'd ask in case there might be a bug.

    Thoughts?

    Hi Lynda,

    The description of your configuration, it looks like the wholesaler variable is not available in the context of the licensee of content or layout. Take a look at this article - custom modules parameter passing and pass the value of the variable of wholesaler for the contentholder module by using a custom setting, something like

    {module_contentholder id = "123" myCustomParameter = "{{China}}"}

    in the context of licensed content should be available in:

    {{params.myCustomParameter}}

  • Why the object_not_found exception does not work?

    Posters,

    I have the following statement in a package.procedure:

    -- (...)
    Start

    Select dbms_metadata.get_dependent_ddl ('INDEX', 'OWNER', sTableName)
    in the cDDL - clob for index DDL
    of the double
    -- (...)

    exception
    When dbms_metadata.object_not_found then
    null;

    end;
    -- (...)

    Execution is stopped in the select, not enter the exception and the following message is displayed in PL/SQL Developer MicroHelp:

    + "ORA-31608: specified object type INDEX not found." + "

    I did it another way by adding the following clause:

    -- (...)
    Start

    Select dbms_metadata.get_dependent_ddl ('INDEX', 'OWNER', sTableName)
    in the cDDL - clob for index DDL
    of the double
    where exists (select 1+)
    of all_indexes+.
    where table_owner = 'OWNER'+.
    and table_name = sTableName); +
    -- (...)

    exception
    + When no_data_found then +.
    null;

    end;
    -- (...)

    It works, but: why the object_not_found exception does not work?

    Thanks in advance for everyone!
    Philips

    Oh I just noticed:

    What happens if instead of this:

    Select dbms_metadata.get_dependent_ddl ('INDEX', 'OWNER', sTableName)
    in the cDDL - clob for index DDL
    of the double

    you say:

    cDDL: = dbms_metadata.get_dependent_ddl ('INDEX', 'OWNER', sTableName);

    ?

  • CouponPrinter.exe does not work. I can download and run the program, but does not, print already added the file name to the list of java exceptions

    running windows xp, update java 7 51, norton antivirus says file is ok, please help

    HI DJDOLLARROB,

    Thanks for posting, as you might expect, there are troubleshooting you can undertake to check why the download does not work. It is highly possible that the source that you have downloaded from cannot be no longer works. Is there a site that you can check to see if it does not work for them either? Also where it is downloaded from?

    Otherwise please see if scanitemswhendone is enabled: change what Firefox does when you click on or download a file

    If download hangs at the last minute (just before reaching 100%), the cause may be an antivirus software that tries to parse the file and during this process the instance of Firefox crashes.

    To resolve the issue, try disabling the analysis as follows:

    1. In the address bar, type Subject: config and press enter. The subject: config "this might void your warranty!" warning page may appear.
    2. Click on I'll be careful, I promise!, to continue on the subject: config page. A list of parameters must appear
    3. Filter the list by typing in the search bar at top. Enter scanWhenDone. Now you should find the "browser.download.scanWhenDone" preference.
    4. Double-click this preference to set the value to false.
    5. Then, try to download something and see if it still crashes.

    Please reply and let us know if this helped you!

  • Home page is empty except for a search bar that does not work and an information bar that is empty.

    'Google' is missing from the left of the search bar, the search bar does not work, the Info window is empty, the button 'Restore previous Session' is missing and the Firefox/Google toolbar with g-mail, hot mail, cards, etc is missing.

    Try to move only the files you really need like bookmarks (bookmarks places.sqlite or restore from a JSON backup in the bookmarkbackups folder) and recorded the names and passwords (signons3.txt and signons.sqlite) and others saved form data (formhistory.sqlite) and make a backup of the files before replacing them, so that you can come back if the problem comes back.

  • I downloaded FF6 on my desktop and my laptop, both work except that RoboForm does not work my office and my laptop will be. Cannot understand it.

    When I downloaded the new update on my laptop there is a notice that add ons would not work, RoboForm has not been included and works very well. Then I upgraded to FF6 on the desk and he was on the list and does not work.

    RoboForm Lite Password Manager 2.1.0

    Check and tell if its working.

  • All my sounds work very well on my iPhone more 6s except the 'duck' sound does not work

    MY iPhone, 3 week old 6 s more, 64 GB using iOS 9.2...

    for my "Mail" alert sound stopped working during the night.  The phone always vibrates when I get an email but th 'Duck' sound is no longer working.

    When I change to use any sound, new sound works fine. ONLY THE DUCK SOUND does not work.

    Any ideas on how to fix my sound 'duck '?

    In fact, my Duck sound won't work for any alert. It cannot be tested as a sound signal.  It's like my Duck sound flew. And I'm not kidding.

    its just gone!

  • Y580 Turbo Boost does not work except if hooked up

    While watching a youtube HD video, I noticed the processor did not work properly and that's why the video was stuttering. I checked and the intel turbo boost on a monitor version 2.6 and it showed that even on dynamic graphics Lenovo plan power than the processor was not using turbo boost. When running on the battery, the monitor displays also a leaf green and written below is "Energy Saver". If I plug the charger in the laptop, the problem goes away and I can see the Turbo works very well and with it the sheet and the "Energy Saver" will too.

    I've changed developed and even power settings made the processor state minimum 100% of battery, just as connected, so that it works just as well, but nothing helps. So I would like to know why the turbo boost function does not work then on the battery and only plugged him.

    yurajgill10,

    Intel's mode require more power that the battery can supply so it works only when the AC is plugged.

    Hope that helps.

  • screen saver does not work didn't sleep except when I click on sleep

    I have set up the screen saver after 2 minutes, but does not work. I also find "sleep" mode does not end defined time. the onl time it works, that's if I manually order the day before in the start menu. any suggestions?

    Hello

    What operating system is installed on the computer?

    Method 1: To help resolve the error and other messages, you can start Windows by using a minimal set of drivers and startup programs. This type of boot is known as a "clean boot". A clean boot helps eliminate software conflicts.

    Try to perform the clean boot and check if it helps, here is the link:
    http://support.Microsoft.com/kb/929135

    Note: When you're done to diagnose, follow step 7 in the article to start on normal startup.

    Method 2: Follow the below mentioned article:

    Windows 7 is not going to sleep:

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

Maybe you are looking for

  • Tecra 8100 memory module questions

    Does anyone know if the ram PC133 144 pin for the Tecra 8200 can be used in the Tecra 8100? I think that the Tecra 8100 usually takes PC100 144 pin but I'm having a hard time getting suppliers to tell me about the PC133 so (probably because it is hal

  • Cannot install Win 8.1 on Satellite click Mini L9W - B

    Hello I bought the mini clik and I want to get rid of windows preinstalled 8 and get a clean installation fee to my windows 8.1 pro, but I can't. I boot with my boot from usb windows 8.1 but it s frozen, I have just the menu where you can select your

  • Director of presentation (Fn + F7) defective keyboard shortcut.

    In Director presentation fn + f7 settings I chose to show me the menu system to choose display. But whenever I connect a wire outside display port and try the keyboard shortcut does not show me the menu, it automatically traverses the various options

  • my pc for the development planning

    my pc becomes slow daily and twice I saw guest that my windows does not normally work in the blue colors.  If I wanted to ask people to tune up my pc tech, what will happen to my antivirus? is there a chance that will offer to change my antivirus, be

  • HP 301 CR340EE: Purchase cartridges

    I have a HP Deskjet 1050 J410 series all-in-one. Why is it impossible to buy HP 301 CR340EE for printer ink cartridges? Even going to the HP support service that I am told. "No supplies. Enter another printer"what do want me to. Buy an another printg