Skip to Content.
Sympa Menu

freetds - [freetds] RE: Bug in SQLNumResultCol function?

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: jun_chen AT bankone.com
  • To: freetds AT lists.ibiblio.org
  • Subject: [freetds] RE: Bug in SQLNumResultCol function?
  • Date: Thu, 10 Jun 2004 11:49:21 -0400

freddy77,

Oracle support told me that Oracle informed freetds the issue and freetds
knew it. describe table <table name> is also a command in IBM DB2.
In Oracle 9i and up, the command is describe <table name>. Oracle support
said the command describe has to work in order for oracle to use the odbc
driver.

The version of freetds I'm using is 0.62.3 which I downloaded about one
month ago (the stable version).
I turned on the logging by export TDSDUMP=/admin/home/oracle/freetds.log
and added the following entries
to odbc.ini:

tracefile = /admin/home/oracle/odbc.log
trace = on

Then I run select * from "scProblem"@msticket from Oracle sqlplus and got
the following errors:

select * from "scProblem"@msticket
*
ERROR at line 1:
ORA-00942: table or view does not exist
[Generic Connectivity Using ODBC]DRV_DescribeTable: Record scProblem has
no
fields. Loading failed
ORA-02063: preceding 2 lines from MSTICKET

But nothing showed up in freetds.log and odbc.log. How can I turn on the
trace in unixodbc and freetds? Did I do everything right?

If I run the unixodbc command isql -v peregrine <user name> <password> and
then the following command describe table scProblem,
here is the log freetds.log.



Then I emptied the log file and run select count(ticket_nbr) from
scProblem, here is the log file:



Thanks.

Jun

Date: Thu, 10 Jun 2004 08:45:34 +0200
From: "ZIGLIO, Frediano, VF-IT" <Frediano.Ziglio AT vodafone.com>
Subject: RE: [freetds] Bug in SQLNumResultCol function
To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
Message-ID:
<F7F148C986A2A84F930FEB8C3B169EA025C617 AT OPDMEXO01.omnitel.it>
Content-Type: text/plain; charset="us-ascii"

>
> Hi,
>
> I am trying to use unixODBC and freetds for Oracle Generic
> Connectivity so
> that I
> can create database links to MS SQL Server in Oracle 10g database.
>
> I can run the unixodbc command isql -v <MS DB Name> <user
> name> <password>
> to connect to the MS SQL Server and run the sql query
> succssfully select *
> from scProblem.
> But the same query select * from "scProblem"@msticket doesn't work by
> using the database link msticket of the MS SQL server.
> Oracle support verified that the configuration of the db link
> is fine. I
> can run the following queries successfully:
> 1) select * from dual@msticket;
> 2) select * from all_catalog@msticket;
>
> Oracle support told me the reason that query select * from
> "scProblem"@msticket doesn't work is that known bugs in freetds.
> The bugs are:
> 1) "describe table scProblem" doesn't work in freetd
>
>
> 2) In SQLNumResultCol function, freetds may return something
> similar to:
>
>
> [ODBC][22261][SQLNumResultCols.c][233]
> Exit:[SQL_SUCCESS]
> Count = ffbed858 -> 0
>
> instead of returning the real number of rows.
>
> when I run the query select * from "scProblem"@msticket.
>
> Could someone verify that? If so, are there any patches for them?
>
> Thank a lot in advanced.
>
> Jun
>

Hi Jun!

First you must use 0.63 version. We can't help with tests cause we don't
own Oracle + binder. Please enable unixODBC log and freetds log and post
them. If data contain sensitive data please send them privately to me
(or James).

I never see "describe table scProblem" syntax before... Perhaps it's an
Oracle syntax??

freddy77

This transmission may contain information that is privileged, confidential
and/or exempt from disclosure under applicable law. If you are not the
intended recipient, you are hereby notified that any disclosure, copying,
distribution, or use of the information contained herein (including any
reliance thereon) is STRICTLY PROHIBITED. If you received this transmission
in error, please immediately contact the sender and destroy the material in
its entirety, whether in electronic or hard copy format. Thank you.

Attachment: freetds.log
Description: Binary data

Attachment: freetds.log
Description: Binary data




Archive powered by MHonArc 2.6.24.

Top of Page