[thelist] SQL Dates

Schenk, Fred FSchenk at RodamcoNederland.nl
Mon Jan 6 10:47:10 CST 2003


	Sorry about the flow of the message, but the Outlook-quotefix
doesn't work here :-(

	There could be a problem with the asp- and the sql-dates if the
languages of the database and the iis-server differ. I for once had to work
with a sql server which was installed as 'dutch'. It might seem to make
sence since I'm dutch too, but it screwed up all the asp-code. Two possible
ways to bypass this are
	1. Set the database language when opening a connection
	2. Use special queries with an {d 'yyyy-mm-dd'} for insert/update
and CONVERT(CHAR(10), dtField, 111) for selects.

	I prefer this second method.

	Gtx,
	      Fred Schenk

> -----Oorspronkelijk bericht-----
> Van:	rudy [SMTP:r937 at interlog.com]
> Verzonden:	vrijdag 3 januari 2003 18:05
> Aan:	thelist at lists.evolt.org
> Onderwerp:	Re: [thelist] SQL Dates
>
> > SQL is really picky about what format you use when using dates, and this
> > can often cause many hours of pulling your hair out. I speak from
> > experience.
>
> i understand your frustration   ;o)
>
> > The normal Date() or  Now() functions will often throw up unexpected
> > errors
>
> um, no
>
> they work just fine, and if you are having problems, let's see your
> problems, because i'll buy you a coffee *and* a doughnut if you can
> actually
> prove that those functions don't work even once
>
> > (don't forget to use those delimiters [#'s] when working with dates!)
>
> this would apply only to microsoft access, hardly a very good example of a
> database that is compliant with standard sql
>
> by the way, those delimiters are called octothorps
>
> ;o)
>
>
> rudy
>
> --
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
>
> For unsubscribe and other options, including the Tip Harvester
> and archives of thelist go to: http://lists.evolt.org
> Workers of the Web, evolt !
>
>
****************************************************************************
The information contained in this communication is confidential and may be
legally privileged. It is intended solely for the use of the individual or
entity to whom it is addressed and others authorised to receive it. If you
are not the intended recipient you are hereby notified that any disclosure,
copying, distribution or taking any action in relation to the contents of
this information is strictly prohibited and may be unlawful. Neither the
sender nor the represented institution are liable for the correct and
complete transmission of the contents of an e-mail, or for its timely
receipt.
****************************************************************************





More information about the thelist mailing list