Solved

Why am I getting "Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another."

Posted on 2011-03-16
7
409 Views
Last Modified: 2012-05-11
I am using classic ASP to access records on an Oracle database.

The connection string I am using works with other tables on the database with no issues.

If I comment out the RS4 portion of this code the page runs fine and displays the other values...just not the tech values.

The database guy I am working with says he gets records returned while using Microsoft Query. I've even changed the query to a basic form of "select this from that" and still the same error.

When I run this part of the code (attached) I get:

ADODB.Recordset (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
/web/report.asp, line 378

with line 378 being:

RS4.OPEN sqlTechQry, oConnMTV, 3,3

I'm not sure if there is an issue with the database connection string or something else. The attached code has the oracle connection string I am using and the code.

Any help would be appreciated. Document1.txt
0
Comment
Question by:Donnie Walker
  • 3
  • 2
  • 2
7 Comments
 
LVL 14

Expert Comment

by:ajexpert
ID: 35152798
Can you print the query in HTML page before RS4.OPEN

debug.print(sqlTechQry)

RS4.OPEN sqlTechQry, oConnMTV,3,3
0
 

Author Comment

by:Donnie Walker
ID: 35153161
I get this error:

Microsoft VBScript runtime (0x800A01B6)
Object doesn't support this property or method: 'debug.print'

But I have printed out the query and confirmed it does work with Microsoft Query.
0
 
LVL 14

Expert Comment

by:ajexpert
ID: 35153184
May be you need to debug little more

Here are the steps to debug

http://www.codeproject.com/KB/debug/DebugVBScriptVS2008.aspx

0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 33

Expert Comment

by:Big Monty
ID: 35156780
i would change your rs4.open statement to:

set RS4 = oConnMTV.Execute( sqlTechQry )

since you're not updating the recordset, it's better (performance-wise) to do it this way.
0
 

Author Comment

by:Donnie Walker
ID: 35157363
When I do that I get this error:

Microsoft OLE DB Provider for Oracle (0x80040E0C)
Command text was not set for the command object.
0
 
LVL 33

Accepted Solution

by:
Big Monty earned 500 total points
ID: 35157520
this usually indictaes something wrong with the query. can you test out a simple select statement using the syntax I provided, just so we can debug it further?
0
 

Author Closing Comment

by:Donnie Walker
ID: 35227205
Thanks! Your suggestion led me to examine my code and I discovered I was calling a function inside a larger function and that was causing the error.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Select case on click 3 19
capture vmstat info and insert it into an oracle table 31 35
Asp in script 6 37
oracle differnce between two timestamps 5 31
Working with Network Access Control Lists in Oracle 11g (part 1) Part 2: http://www.e-e.com/A_9074.html So, you upgraded to a shiny new 11g database and all of a sudden every program that used UTL_MAIL, UTL_SMTP, UTL_TCP, UTL_HTTP or any oth…
Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question