Showing posts with label odbc. Show all posts
Showing posts with label odbc. Show all posts

Monday, March 19, 2012

multiple unnamed paramaters

Please give me an idea as to how I should be mapping my query parameters, if
i have more than one - to report parameters when using ODBC data
source(which supports only unnamed paramaters?)Related previous post:
http://msdn.microsoft.com/newsgroups/default.aspx?dg=microsoft.public.sqlserver.reportingsvcs&mid=fe557b51-0171-46a7-9af0-6940b9e04dd2.
--
Ravi Mumulla (Microsoft)
SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"NU" <vidhuvaradan@.rediffmail.com> wrote in message
news:eoGk%23lYbEHA.2812@.tk2msftngp13.phx.gbl...
> Please give me an idea as to how I should be mapping my query parameters,
if
> i have more than one - to report parameters when using ODBC data
> source(which supports only unnamed paramaters?)
>|||Thanks, that helped.
"Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in message
news:O23MKFabEHA.1652@.TK2MSFTNGP09.phx.gbl...
> Related previous post:
>
http://msdn.microsoft.com/newsgroups/default.aspx?dg=microsoft.public.sqlserver.reportingsvcs&mid=fe557b51-0171-46a7-9af0-6940b9e04dd2.
> --
> Ravi Mumulla (Microsoft)
> SQL Server Reporting Services
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> "NU" <vidhuvaradan@.rediffmail.com> wrote in message
> news:eoGk%23lYbEHA.2812@.tk2msftngp13.phx.gbl...
> > Please give me an idea as to how I should be mapping my query
parameters,
> if
> > i have more than one - to report parameters when using ODBC data
> > source(which supports only unnamed paramaters?)
> >
> >
>

Friday, March 9, 2012

Multiple Step OLE DB error from VB

One of our users is getting this error message.

Microsoft OLE DB Provider for ODBC Drivers (0x80040E21) Multiple-step OLE DB operation
generated errors. Check each OLE DB status value, if available. No work was done.

This is the only user that is currently getting the message. Last week another user got this one day and then it stopped.

Inside VB6 code, we're sending some filters to an ASP that in turn sends a SELECT based on those parameters the SQL database and we get data back to the program.

Stepped through the code and found the error returns after this line

oSqlServConn.Open "Provider=MSDAOSP;Data Source=MSXML2.DSOControl.2.6"

Any thoughts out in ForumLand? Please take it easy on me since I didn't write most of this code. Just trying to solve the problem. :)Check if this (http://support.microsoft.com/default.aspx?scid=kb;en-us;312288) pertains to your situation.|||Nope. Unfortunately not. Only sending a handful of filters and the user has Service Pack 4 already. Wouldn't be as concerned (since this is a user that rarely needs the data and can get it via other means) except this person has the newest computer on the block.|||Still having this problem. Any thoughts out there?|||Check tables names and columns names in SQL. I think there may be issue in deploying columns referred by the page.

Check the following :
Use client-side cursors (by setting the ADO recordset Cursor Location property to adUseClient).
Remove the insert trigger from the source table.
Put SET NOCOUNT ON line at the beginning of the trigger code.
After calling Update the first time to insert the new row in the table, scroll the recordset using methods like MoveNext and MovePrevious before calling Update again.

HTH|||Setting cursor location may affect the situation, but the rest simply does not apply, - the error occurs at the time of initializing the connection, not at the time of execution of an action query that fires a trigger.|||Tried setting cursor location on either side of the equation and still no go. I can recreate the problem on my computer now as long as I'm pointing to a test SQL server. When I switch over and point to our Production SQL server, I get no error.

Multiple statement handles on one connection

I want to use multiple concurrently active statement
handles on a single connection handle. An ODBC call to
SQLGetInfo with the SQL_ACTIVE_STATEMENS key returns 1,
indicating that there is a limit of 1 active statement on
a single connection. If I try to SQLExecDirect on another
statement handle on the same connection handle I get an
error complaining that there is another active statement
on the same connection.
Is there any way to configure either SQLServer or its ODBC
driver to allow multiple concurrently active statement
handles on the same connection? This is pretty common
database programming practice to Exec one query, then use
a loop with SQLFetch and then execute multiple SQL
statements on another statement handle within the loop.
Even lowly MSAccess allows multiple concurrently active
statement handles on the same connection.
My ODBC driver version is 2000.85.1022.00.
My SQLServer version SQL Server Developer Edition 8.00.194
(RTM)This is not possible with current versions of SQL Server or the SQL Server
ODBC Driver, when using the default "firehose" cursor. You can use
server-side cursors, which allow you to fetch a single row at a time from
the server (and therefore free up the connection between each row), or you
can cache the data from the first statement yourself (therefore freeing up
the connection). And of course, you can open up a second connection for the
second statement.
Brannon Jones
Developer - MDAC
This posting is provided "as is" with no warranties and confers no rights.
"Lee Scheffler" <anonymous@.discussions.microsoft.com> wrote in message
news:b47e01c4077d$ef011af0$a101280a@.phx.gbl...
> I want to use multiple concurrently active statement
> handles on a single connection handle. An ODBC call to
> SQLGetInfo with the SQL_ACTIVE_STATEMENS key returns 1,
> indicating that there is a limit of 1 active statement on
> a single connection. If I try to SQLExecDirect on another
> statement handle on the same connection handle I get an
> error complaining that there is another active statement
> on the same connection.
> Is there any way to configure either SQLServer or its ODBC
> driver to allow multiple concurrently active statement
> handles on the same connection? This is pretty common
> database programming practice to Exec one query, then use
> a loop with SQLFetch and then execute multiple SQL
> statements on another statement handle within the loop.
> Even lowly MSAccess allows multiple concurrently active
> statement handles on the same connection.
> My ODBC driver version is 2000.85.1022.00.
> My SQLServer version SQL Server Developer Edition 8.00.194
> (RTM)

Saturday, February 25, 2012

Multiple Servers in ODBC Client Setup

OK, something weird is happening.
I have a standard Windows XP client and I am trying to set up a simple ODBC
entry. So I go to Control Panel/Administrative Tools/ODBC/System Tab. From
there I create a new ODBC entry connecting to a SQL Server. I enter in the
name of my ODBC and a descripton. When I hit the drop-down button to select
a server I see my 2 SQL Server machines (local machine also named "Jim" and
sbserver) but they are listed twice or even 3 times (see below) and the local
machine has even more entries. What gives and how do I clean this up? Both
seem to work when I "test" at the last step but I have a local application
using this ODBC and it is failing to run so I think it is having "issues"
with these multiple entries.
Thanks!
-Richard
e.g.
(local)
(local)
Jim
Jim
jim
sbserver
sbserver
Make sure your MDAC installation isn't flaky - you can use
component checker to verity the MDAC version and
installation. You can download the tool from:
http://msdn2.microsoft.com/en-us/data/aa937730.aspx
How many instances do you have on each of those servers?
Do you get the same list if you execute the following from
the command prompt:
osql -L
-Sue
On Fri, 16 Mar 2007 04:47:05 -0700, Richard K
<RichardK@.discussions.microsoft.com> wrote:

>OK, something weird is happening.
>I have a standard Windows XP client and I am trying to set up a simple ODBC
>entry. So I go to Control Panel/Administrative Tools/ODBC/System Tab. From
>there I create a new ODBC entry connecting to a SQL Server. I enter in the
>name of my ODBC and a descripton. When I hit the drop-down button to select
>a server I see my 2 SQL Server machines (local machine also named "Jim" and
>sbserver) but they are listed twice or even 3 times (see below) and the local
>machine has even more entries. What gives and how do I clean this up? Both
>seem to work when I "test" at the last step but I have a local application
>using this ODBC and it is failing to run so I think it is having "issues"
>with these multiple entries.
>Thanks!
>-Richard
>e.g.
>(local)
>(local)
>Jim
>Jim
>jim
>sbserver
>sbserver