RE: Oracle Computed column datatype
- From: "SPaquin" <spaquin@xxxxxxxxxxxxxxxx>
- Date: Thu, 21 Jul 2005 05:35:03 -0700
Hi
In my example, the weight column is defined as number(5). The statement
select weight
,weight/2000 tons
from abc;
is executed and the result inserted in a ADODB.Recordset. Looking at the
column datatype of the recordset fields, I get adNumeric for column weight
but I get adVarWChar for the tons computed column. I expected the tons column
to be numeric since weight is a number datatype. So my questions are:
What is the behavior of the MS OLEDB Oracle driver in regards to Oracle
computed columns ?
How can the programmer influence this behavior ?(I want the tons column to
be numeric)
For your questions:
1) Obviously weight and weight/2000 give different value results... I am
concerned with datatype of those 2 columns in the resulting recordset. The
first is numeric. The second is character even though weight/2000 gives a
numeric result.
2) Weight is number(5).
3) SQL Server works OK, I know that. But my data is in Oracle.
4) I have not tried other numeric datatypes other than number.
TIA
SP
"Kevin Yu [MSFT]" wrote:
> Hi,
>
> First of all, I would like to confirm my understanding of your issue. From
> your description, do you mean that after opening the Recordset, Print
> rs.Field("weight").Type and Print rs.Field("tons").Type return different
> values? If there is any misunderstanding, please feel free to let me know.
>
> Could you let me know which data type the column weight is using? It works
> fine if I use SQL server. So I will try to do some research if I use it on
> Oracle. Will this also happen if you use other numeric types?
>
> Kevin Yu
> =======
> "This posting is provided "AS IS" with no warranties, and confers no
> rights."
>
>
.
- Follow-Ups:
- RE: Oracle Computed column datatype
- From: Kevin Yu [MSFT]
- RE: Oracle Computed column datatype
- References:
- Oracle Computed column datatype
- From: SPaquin
- RE: Oracle Computed column datatype
- From: SPaquin
- RE: Oracle Computed column datatype
- From: Kevin Yu [MSFT]
- Oracle Computed column datatype
- Prev by Date: Re: ADODB Recordset Open method crashes Calling program
- Next by Date: CommitTrans of object _Connection failed
- Previous by thread: RE: Oracle Computed column datatype
- Next by thread: RE: Oracle Computed column datatype
- Index(es):
Relevant Pages
|
|