Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Update a date field using ADO

Re: Update a date field using ADO

From: Alexei VORONOV <alexei_voronov_at_yahoo.com>
Date: Mon, 22 Oct 2001 13:07:01 +0200
Message-ID: <9r0uk9$39i$1@wanadoo.fr>


Yes, but here there is a need to fill a recordset field by value, and may be it cannot accept a function within, that depends on OLEDB provider, but one can try with function if this work or not.

"Keith Jamieson" <Keith.Jamieson_at_phoenix.ie> a écrit dans le message news: 9r0s1l$5n2$1_at_kermit.esat.net...
> I generally take the approach of having both the date and the oracle date
> format mask passed in as strings, and then convert them using to_date.
This
> way, it doesn't matter what the nls_date_format is set to.
>
> Alexei VORONOV wrote in message <9qmhdl$hlr$1_at_wanadoo.fr>...
> >probably you can try to set NLS_DATE_FORMAT for the session (alter
session
> >stmt), and after give the formatted string instead of using UTC.
> >For exapmle:
> >altersession set NLS_DATE_FORMAT='DD/MM/YYYY HH24:MI:SS'
> >
> >rs.Fields("data_nascita").Value="31/7/2002 23:15:00";
> >
> >"Francesco" <jazz74_removeThis_at_infinito.it> a écrit dans le message news:
> >9qmad1$hpm$1_at_fe2.cs.interbusiness.it...
> >> Hi everybody, that's the big trouble: I use ADO with oracle (using
OLEDB
> >> connection), and I get an error while I try to update a date field:
> >> checkData() return a Date in UTC format. (Wed Jul 31 00:00:00 UTC+0200
> >2002)
> >>
> >> var rs=Server.CreateObject("ADODB.recordset");
> >> rs.Open("select * from TABLE where PK_FIELD=100000",cn);
> >> rs.Fields("data_nascita").Value=checkData("31/7/2002");
> >> rs.Update();
> >> rs.Close;
> >>
> >> Where can I find good articles or forums about using ADO with Oracle?
> >> Thanks in advance.
> >>
> >> Francesco
> >>
> >>
> >
> >
>
>
Received on Mon Oct 22 2001 - 06:07:01 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US