|
 |
asp_databases thread: date function get 1899 in access database
Message #1 by dont worry <aspmailbox@y...> on Thu, 8 Nov 2001 08:40:25 -0800 (PST)
|
|
I use date() function to insert current date into
access database table and it inserts 1899 ..... On the
asp page response.write it gives correct date?
thanks
__________________________________________________
Do You Yahoo!?
Find a job, post your resume.
http://careers.yahoo.com
Message #2 by David Cameron <dcameron@i...> on Fri, 9 Nov 2001 09:16:37 +1100
|
|
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01C168A3.08AF51F0
Content-Type: text/plain
www.adopenstatic.com/faq/dateswithaccess.asp
regards
David Cameron
nOw.b2b
dcameron@i...
-----Original Message-----
From: dont worry [mailto:aspmailbox@y...]
Sent: Friday, 9 November 2001 2:40 AM
To: ASP Databases
Subject: [asp_databases] date function get 1899 in access database
I use date() function to insert current date into
access database table and it inserts 1899 ..... On the
asp page response.write it gives correct date?
thanks
__________________________________________________
Do You Yahoo!?
Find a job, post your resume.
http://careers.yahoo.com
$subst('Email.Unsub')
Message #3 by "Ken Schaefer" <ken@a...> on Fri, 9 Nov 2001 12:27:23 +1100
|
|
How are you putting the date *into* Access in the first place?
Cheers
Ken
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "dont worry" <aspmailbox@y...>
Subject: [asp_databases] date function get 1899 in access database
: I use date() function to insert current date into
: access database table and it inserts 1899 ..... On the
: asp page response.write it gives correct date?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Message #4 by Pappas Nikos <pappas@c...> on Fri, 09 Nov 2001 10:42:10 +0200
|
|
Hi Ken
Sorry to jump in like that
inssql = "INSERT INTO ADVBYCATEG (PICTURE,description,CATEGORY,url,DATEIN)"
inssql =inssql & " VALUES "
inssql =inssql & " ('" & request.form("PICTURE") & "','" & request.form("description") & "','" &
request.form("ATEGORY") & "','" & request.form("url") & "',date());"
myConnection.execute inssql
This works fine with me using acces 2000
All the best
Nikos
At Friday9/11/2001, you wrote:
>How are you putting the date *into* Access in the first place?
>
>Cheers
>Ken
>
>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>From: "dont worry" <aspmailbox@y...>
>Subject: [asp_databases] date function get 1899 in access database
>
>
>: I use date() function to insert current date into
>: access database table and it inserts 1899 ..... On the
>: asp page response.write it gives correct date?
>
>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
Message #5 by dont worry <aspmailbox@y...> on Sat, 10 Nov 2001 09:34:47 -0800 (PST)
|
|
sqlAdd = " INSERT INTO Mailing_List " & _
" (ListType, EmailAddress, DateJoined,
MembershipStatus, DateUpdated) " & _
" VALUES ('NewsLetter', '"
emailAddress& "', "&date()&",
'ACTIVE', "&date()&" ) "
cn.Execute sqlAdd, numa
In access 97,
Thanks
--- Ken Schaefer <ken@a...> wrote:
> How are you putting the date *into* Access in the
> first place?
>
> Cheers
> Ken
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> From: "dont worry" <aspmailbox@y...>
> Subject: [asp_databases] date function get 1899 in
> access database
>
>
> : I use date() function to insert current date into
> : access database table and it inserts 1899 ..... On
> the
> : asp page response.write it gives correct date?
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
> aspmailbox@y...
> $subst('Email.Unsub')
>
__________________________________________________
Do You Yahoo!?
Find a job, post your resume.
http://careers.yahoo.com
Message #6 by "Ken Schaefer" <ken@a...> on Mon, 12 Nov 2001 12:39:27 +1100
|
|
Either use the builtin Date() function in Access to insert the current
date/time, or, if you want to use the VBScript Date() function, you need to
enclose your date/time field values with #
You do not delimit date values with ' when using Access/Jet
Cheers
Ken
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "dont worry" <aspmailbox@y...>
Subject: [asp_databases] Re: date function get 1899 in access database
: sqlAdd = " INSERT INTO Mailing_List " & _
: " (ListType, EmailAddress, DateJoined,
: MembershipStatus, DateUpdated) " & _
: " VALUES ('NewsLetter', '"
: emailAddress& "', "&date()&",
: 'ACTIVE', "&date()&" ) "
: cn.Execute sqlAdd, numa
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
 |