Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3871462
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T21:49:34+00:00 2026-05-19T21:49:34+00:00

I’m trying to update a table via a stored procedure from asp.net. I get

  • 0

I’m trying to update a table via a stored procedure from asp.net. I get the following error message: “wrong number or types of arguments in call to ‘UPDATE_DIRECT_BILL_DETL_SP'”

I just can’t seem to figure out what is wrong. I believe I may not be using the correct Oracle variable types in my Cmd.Parameter.Add statements.

I appreciate any help that can be provided!

Thank you.

Here are the details:

I’m using Oracle.DataAccess.dll (ODP.NET)

Here is my function:

Public Function UpdateDirectBill(ByVal invDetID As Int32, ByVal appNum As String, _
             ByVal lastUpdtByNm As String) As Int32

    Dim numRecUpdated As Int32 = 0

    Cmd.CommandType = CommandType.StoredProcedure
    Cmd.CommandText = "UPDATE_DIRECT_BILL_DETL_SP"

    'These are the values I'm using for the params
    invDetID = 1
    appNum = "3333"
    lastUpdtByNm = "N015058"

    Cmd.Parameters.Add("invDetID", OracleDbType.Int32,    invDetID,   ParameterDirection.Input)
    Cmd.Parameters.Add("appNum",   OracleDbType.Varchar2, appNum,        ParameterDirection.Input)
    Cmd.Parameters.Add("lastUpdtByNm",  OracleDbType.Varchar2, lastUpdtByNm,  ParameterDirection.Input)
    Cmd.Parameters.Add("numRecUpdated", OracleDbType.Int32,    numRecUpdated, ParameterDirection.Output)

    Conn.Open()
    Cmd.ExecuteNonQuery()
    Conn.Close()

    Dim recsUpdated As Int32 = Convert.ToInt32(Me.Cmd.Parameters("numRecUpdated").Value.ToString())

    Return recsUpdated
End Function

My Stored Procedure:

  PROCEDURE UPDATE_DIRECT_BILL_DETL_SP
  (invDetID     IN invoice_detail.invoice_detail_id%TYPE,
   appNum       IN invoice_detail.application_num%TYPE,
   lastUpdateNm IN invoice_detail.last_update_by_nm%TYPE, 
   rowCnt       OUT number)
  IS
  BEGIN 
    UPDATE INVOICE_DETAIL A
    SET
    A.APPLICATION_NUM=appNum,
    A.LAST_UPDATE_BY_NM = lastUpdateNm, 
    A.LAST_UPDATE_BY_DT=SYSDATE
    WHERE A.INVOICE_DETAIL_ID=invDetID;

    rowCnt := SQL%ROWCOUNT;
    if rowCnt = 1 then
      COMMIT;
    ELSE
      ROLLBACK;
    END IF;
  END UPDATE_DIRECT_BILL_DETL_SP;

The columns I’m updating are of the following types:

   invDetID IN invoice_detail.invoice_detail_id%TYPE        of type Number
   appNum in invoice_detail.application_num%TYPE            of type Varchar2(10 byte)
   lastUpdateNm IN invoice_detail.last_update_by_nm%TYPE    of type Varchar2(50 byte)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T21:49:35+00:00Added an answer on May 19, 2026 at 9:49 pm

    Your parameter names don’t match up ‘rowCnt’ and ‘numRecUpdated’. Also you’re specifying the type as Int in your call, but the stored proc specifies it as a Number which maps to a Decimal. So you would need to specify it either as a OracleDbType.Decimal type rather than an int. Or change your stored proc parameter to an INTEGER http://download.oracle.com/docs/cd/B19306_01/win.102/b14307/OracleDbTypeEnumerationType.htm

    Cmd.Parameters.Add("rowCnt", OracleDbType.Decimal, numRecUpdated, ParameterDirection.Output)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I have a bunch of posts stored in text files formatted in yaml/textile (from
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
Does anyone know how can I replace this 2 symbol below from the string
I am trying to loop through a bunch of documents I have to put
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
Seemingly simple, but I cannot find anything relevant on the web. What is the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.