473,382 Members | 1,431 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,382 software developers and data experts.

OleDbException: Too many arguments.

jn
Hi,

I'm passing around 30 arguments to a stored procedure, and
I got the following error (see below).
It works fine if I narrow down to around 25 args. Is there
any workaround to bypass this exception, I need to pass 30
of them to my stored procedure. Thanks.
I'm using Framework 1.0.

-----------------------
Too many arguments.
Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.

Exception Details: System.Data.OleDb.OleDbException: Too
many arguments.

Source Error:
Line 663:
Line 664: 'execute SQL
Line 665: oCmd.ExecuteNonQuery()
Line 666:
Line 667: 'Catch exc As OleDbException
--------------------------

Nov 18 '05 #1
2 2958
If you have any return parameters, they must be specified first. You should
declare any return parameters before you start adding input parameters. That
is commonly the reason for this error. Also, make sure that the order in
which you are adding your parameters match the order in the stored
procedure.

HTH,
Bill P.
"jn" <an*******@discussions.microsoft.com> wrote in message
news:00****************************@phx.gbl...
Hi,

I'm passing around 30 arguments to a stored procedure, and
I got the following error (see below).
It works fine if I narrow down to around 25 args. Is there
any workaround to bypass this exception, I need to pass 30
of them to my stored procedure. Thanks.
I'm using Framework 1.0.

-----------------------
Too many arguments.
Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.

Exception Details: System.Data.OleDb.OleDbException: Too
many arguments.

Source Error:
Line 663:
Line 664: 'execute SQL
Line 665: oCmd.ExecuteNonQuery()
Line 666:
Line 667: 'Catch exc As OleDbException
--------------------------

Nov 18 '05 #2
JN
arg, I found out it's Visual FoxPro problem (I'm using VFP
as the backend database), it just won't take more than 28
parameters. Thanks, Bill, for looking into my problem
though.

-----Original Message-----
If you have any return parameters, they must be specified first. You shoulddeclare any return parameters before you start adding input parameters. Thatis commonly the reason for this error. Also, make sure that the order inwhich you are adding your parameters match the order in the storedprocedure.

HTH,
Bill P.
"jn" <an*******@discussions.microsoft.com> wrote in messagenews:00****************************@phx.gbl...
Hi,

I'm passing around 30 arguments to a stored procedure, and I got the following error (see below).
It works fine if I narrow down to around 25 args. Is there any workaround to bypass this exception, I need to pass 30 of them to my stored procedure. Thanks.
I'm using Framework 1.0.

-----------------------
Too many arguments.
Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.OleDb.OleDbException: Too
many arguments.

Source Error:
Line 663:
Line 664: 'execute SQL
Line 665: oCmd.ExecuteNonQuery()
Line 666:
Line 667: 'Catch exc As OleDbException
--------------------------

.

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Mark V | last post by:
I am trying out VS web 2005 beta addition with an Access Database. If I try to insert new data into any table in the database I continually get the following error; Seen similar on many...
33
by: Kenneth Brody | last post by:
I know that passing printf() too few arguments, or arguments of the wrong type invokes UB. However, what about passing too many arguments, if the expected arguments are of the correct type? For...
2
by: Ranier Dunno | last post by:
Hi, I'm using an Excel-file generated by a third-party application as input to my C# app. The problem occurs in one of the worksheets in that Excel-file, where there is a single column and no...
3
by: G.Esmeijer | last post by:
Friends, The following code works fin. BUT... after a >> couple times<< this code is used is a class it comes with an error saying unhandled System.Data.OleDb.OleDbException' occurred in...
0
by: silesius | last post by:
I've been using VS 2003 to develop a webapplication using C#. Today I exported the application to a remote webserver I begun experiencing problems. It's a simple application that retrieves some...
2
by: Claudia Fong | last post by:
Hi, Does someone can explain to me why this exception (System.Data.OleDb.OleDbException) occurs and is there a way to prevent it? The whole message is: An unhandled exception of type...
1
by: T8 | last post by:
I have a asp.net (framework 1.1) site interfacing against SQL 2000. It runs like a charm 99% of the time but once in a while I get the following "unspecified error". Sometimes it would resolve by...
5
by: petro | last post by:
Hello all, My asp.net web application works on my machine but I get the following error on our test web server, There is only one oracle home on the test server. Does anyone know how to resolve...
10
by: Alan G Isaac | last post by:
My class MyClass reuses many default parameters with a small number of changes in each instance. For various reasons I decided to put all the parameters in a separate Params class, instances of...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: 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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.