/ Forside / Teknologi / Udvikling / ASP / Nyhedsindlæg
Login
Glemt dit kodeord?
Brugernavn

Kodeord


Reklame
Top 10 brugere
ASP
#NavnPoint
smorch 9259
Harlekin 1866
molokyle 1040
Steffanst.. 758
gandalf 657
smilly 564
gibson 560
cumano 530
MouseKeep.. 480
10  Random 410
howto insert today's date into access?
Fra : Morten F. Klausen


Dato : 29-01-01 11:43

Hi!

I'm going to insert today's date into Access 2000! -How?

I've used now(), date() in the insert line, but non of will just use the
date (both of them also use the time!) (for instance to insert 28.01.2001
into access 2000!)
What format should I use in the date field in Access 2000, to combine a
function that will work with the insert sentence in ASP?

So my question is:

If some of you have done this; please tell me how (with access 2000 and
ASP!)

Do some of you know, so please tell me how!!!???

I would be delighted to hear from you!!

Best regards
Morten





 
 
Allan Jensen (29-01-2001)
Kommentar
Fra : Allan Jensen


Dato : 29-01-01 12:05

>I'm going to insert today's date into Access 2000! -How?
>
>I've used now(), date() in the insert line, but non of will just use the
>date (both of them also use the time!) (for instance to insert 28.01.2001
>into access 2000!)
>What format should I use in the date field in Access 2000, to combine a
>function that will work with the insert sentence in ASP?
>
>So my question is:
>
>If some of you have done this; please tell me how (with access 2000 and
>ASP!)

In ASP you use the function date(). Then you have the value for your
SQL sentence (I'm assume you use an SQL sentence to add data to the
database). But you need to be aware of that the date in the SQL _has_
to be in US format, that means in the month, day, year order. Access
will then handle it according to the regional settings you have on
your computer.

In Access the datatype should be a date/time and the format should be
one where you only show the data and not the time. If you format your
date in both date and time Access will show both no matter how the
value came in in the first place.


Søg
Reklame
Statistik
Spørgsmål : 177557
Tips : 31968
Nyheder : 719565
Indlæg : 6408868
Brugere : 218888

Månedens bedste
Årets bedste
Sidste års bedste