473,386 Members | 1,745 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments in call to

Hi there

Please help with this error ORA-06550

Im trying to call this procedure from within VB. please help with this error

PLSQL
-----
Expand|Select|Wrap|Line Numbers
  1. create or replace procedure sel_barcode (p_barcode OUT VARCHAR2, p_productcode OUT VARCHAR2)
  2.  
  3. is
  4.  
  5. begin
  6.   select barcode, PRODUCTCODE into p_barcode, p_productcode from barcode where barcode = '00123001';
  7.  
  8.  
  9. end;
  10.  
  11.  
  12.  
  13.  Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
  14.  
  15.   With Me
  16.      Dim con1 As New OracleConnection("Data Source=localhost;User Id=xxx;Password=xxx")
  17.  
  18.       'Declare Variables
  19.       Dim theFnameString, theLnameString As String
  20.       Dim messageString As String
  21.       Dim opBarCode = New SqlParameter("@resBarCode", SqlDbType.NVarChar)
  22.       opBarCode.Direction = ParameterDirection.Output
  23.       opBarCode.Size = 50
  24.  
  25.       Dim opProdCode = New SqlParameter("@resProdCode", SqlDbType.NVarChar)
  26.       opProdCode.Direction = ParameterDirection.Output
  27.        opProdCode.Size = 50
  28.  
  29.        Dim addTherapistCommand As New OracleCommand("sel_barcode ", con1)
  30.        addTherapistCommand.CommandType = CommandType.StoredProcedure
  31.  
  32.  
  33.        addTherapistCommand.Parameters.Add("@resBarCode", OracleType.VarChar, 50).Direction = ParameterDirection.Output
  34.        addTherapistCommand.Parameters.Add("@resProdCode", OracleType.VarChar, 50).Direction = ParameterDirection.Output
  35.  
  36.  
  37.             'Open Connection
  38.                 Try
  39.                     con1.Open()
  40.  
  41.                 Catch ex As Exception
  42.                     MessageBox.Show(ex.ToString())
  43.                 Finally
  44.                 End Try
  45.  
  46.  
  47.                 'Execute oracle "add_therapist" procedure
  48.                 addTherapistCommand.ExecuteNonQuery()
  49.                 addTherapistCommand.Parameters.Clear()
  50.                 addTherapistCommand.Dispose()
  51.                 con1.Close()
  52.  
  53.                 'Clear TextBoxes
  54.                 With Me
  55.                     .theLnameTextBox.Clear()
  56.                     With .theFnameTextBox
  57.                         .Clear()
  58.                         .Focus()
  59.                     End With
  60.                 End With
  61.                 messageString = "Update Complete"
  62.                 MessageBox.Show(messageString, "Database Upadated", MessageBoxButtons.OK, MessageBoxIcon.Information)
  63.             End With
  64.  
  65.         End Sub
Apr 29 '15 #1
1 1762
Rabbit
12,516 Expert Mod 8TB
Please use code tags when posting code or formatted data.

The issue is most likely line 6. You can only SELECT ... INTO 1 table, not multiple tables.
Apr 29 '15 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Pial | last post by:
Hi : I am using Asp.Net, C#, Oracle . I am trying to execute this Stored Procedure, and it gives me an error "Error Message: ORA-06550: line 1, column 7: PLS-00306: wrong number or types of...
4
by: Martin Magnusson | last post by:
I'm using a matrix and vector library, that won't compile. When running g++ I get the error message "macro "minor" passed 5 arguments, but takes just 1" The definition of "minor" looks like...
1
by: Java Guy | last post by:
I'm trying to view a web page. IE tells me there are (Java?) errors on the page. Here they are: Line: 15 Char: 7 Error: Wrong number of arguments or invalid propert assignment Code: 0 URL:...
6
by: tinareed | last post by:
Please help out a newbie. I've copied a complicated query and am trying to modify it for mailing labels. First, last name and primary address are the fields. Primary address would be either a home...
1
by: alhalayqa | last post by:
hi guys, I have XML node object o,and I am trying to know if getAttribute is a function in the object o, by using if(typeof o.getAttribute == 'function'), now firefox returns "function", but IE...
3
by: vunet | last post by:
Hello, I've just installed ASPXMLRPC library and testing their main function: xmlRPC ("URL", "command_name", params) The function converts all parameters to XML, sends a request to third-...
0
by: James Mills | last post by:
On Fri, Oct 31, 2008 at 8:49 AM, mark floyd <emfloyd2@gmail.comwrote: Mark, this is correct behavior. You have 3 positional arguments in the function definition. You _must_ aupply _all_ 3 of...
2
by: Steven Hayes | last post by:
Thanks for any help I'm new at this. I have the following excel statement: =IF(B131="", "Input UFMIP", IF((B131-B133)<0, 0, IF(B131>0, B131-B133, 0))) I tried unsuccessfully to convert to...
2
by: Dave Smith | last post by:
Hi everyone again. I’m working on making my database roll with each month that changes. Below is what I have so far, and was hoping someone could help me with the rest. The error message I’m...
0
by: Peter Moh | last post by:
I get wrong number of arguments (0 for 1) error. The create action works with regular validates but authenticate/salt processing. Please point out what does the message mean? The create...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.