troubleshooting Question

Why am I getting a Oracle numeric or value error

Avatar of bschave2
bschave2 asked on
.NET ProgrammingOracle Database
13 Comments1 Solution215 ViewsLast Modified:
I have a procedure that has 2 input paramaters to verify the username and password. I also have three 3 integer output parms to pass me back some info. Now I want to add a varchar2 value back as well giving me the first name of the user. The problem is I keep getting a numeric or value error and cannot figure out why. Can someone please shed some light on this for me? My code is attached.
PROCEDURE VerifyCounterparty(
    v_EmailAddress IN VARCHAR,
    v_Password     IN VARCHAR2,
    v_Count OUT NUMBER,
    v_AccountLocked OUT NUMBER,
    v_TradesCompanyId OUT NUMBER,
    v_FirstName OUT VARCHAR2)
IS
BEGIN
  SELECT COUNT(firstname) firstname,
    ACCOUNTLOCKED,
    TRADESCOMPANYID,
    FIRSTNAME
  INTO v_Count,
    v_AccountLocked,
    v_TradesCompanyId,
    v_FirstName
  FROM T_USER
  WHERE EMAILADDRESS = v_EmailAddress
  AND PASSWORD       = v_Password GROUP BY ACCOUNTLOCKED, TRADESCOMPANYID, FIRSTNAME;
EXCEPTION
WHEN NO_DATA_FOUND THEN
  v_Count           := 0;
  v_AccountLocked   := 0;
  v_TradesCompanyId := 0;
END VerifyCounterparty;

Open in new window

ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 1 Answer and 13 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 13 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros