Use DBB > #05/25/1969#
-----Original Message-----
From: Slikker Peter
[mailto:mssqldba-ezmlmshield-x42137376.[Email address protected]
Sent: 28 February 2007 2:39 PM
To: LazyDBA Discussion
Subject: RE: Access Date query
No need to do substring and such.. Just declare constants in the format
you want and use format$...
E.g.
Assume YourDate is a datetime... Say Jan 5 2007
Const DateFmt = "mm\/dd\/yyyy"
Const SQLDateFmt = "yyyymmdd"
Format$(YourDate, SQLDateFmt) gives 20070105
Format$(YourDate, DateFmt ) gives 01/05/2007
And so on...
-----Original Message-----
From: jason
[mailto:mssqldba-ezmlmshield-x69097616.[Email address protected]
Sent: Wednesday, 28 February 2007 7:56 PM
To: LazyDBA Discussion
Subject: RE: Access Date query
one way is to convert the field to text, substring the dd mm and yyyy,
rearrange in the uk format in the function to convert text into a date
value regards
|---------+-------------------------------------------------------->
| | "Carol Green " |
| | <mssqldba-ezmlmshield-x97650324.[Email address protected]
| | om> |
| | |
| | |
| | Wednesday February 28, 2007 08:47 |
| | |
|---------+-------------------------------------------------------->
>-----------------------------------------------------------------------
---------------------------------------|
|
|
| To: "LazyDBA
Discussion" <[Email address protected] |
| cc:
|
| Subject: RE: Access Date query
|
>-----------------------------------------------------------------------
---------------------------------------|
Could you post the context you are using this in (is it a query, string,
sp parameter etc)?
-----Original Message-----
From: Goutam Ghoshal
[mailto:mssqldba-ezmlmshield-x52993964.[Email address protected]
Sent: 28 February 2007 07:02
To: LazyDBA Discussion
Subject: Access Date query
Hi All
I have an Access DB
And there are some date/time fields in some tables.
But i have some problem to get data based on date query
Like in sql server we have lots of option to fetch data based on date
fieds (we can use convert etc)
suppose in a table there is a field name DOB i want to fetch data whose
DBB > '05/25/1969' ('mm/dd/yyyy')
How i get those records?
Regards,
Goutam
---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY To post a
dba job: http://jobs.lazydba.com To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html
This email and any files transmitted within it are private and
confidential.
If you are not the intended recipient, this email and any attachments
within it have been transmitted to you in error.
You are prohibited from using, copying, distributing or otherwise using
the information contained within this email.
Nothing in this email message amounts to a contractual or legal
commitment on the part of Optilan unless confirmed by a communication
signed on behalf of the company.
Any email cannot be guaranteed to be secure, error free or free from
viruses. Although every possible care is taken by Optilan, Optilan does
not accept any liability whatsoever for any loss or damage which may be
caused as a result of the transmission of this message by email.
---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY To post a
dba job: http://jobs.lazydba.com To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html
This e-mail is being sent to you for your information or at your
request.
The information contained in this e-mail is not warranted as to
completeness or accuracy, nor does it serve as an official record of
your account, which is provided only by your trade confirmation or
client account statement from Prudential Bache Commodities, LLC,
Prudential Bache Securities, LLC or Bache Commodities Limited. Since the
confidentiality of Internet e-mail cannot be guaranteed, please do not
include private or confidential information (such as account numbers) or
instructions requiring your authorization (such as orders or funds
transfers) in your e-mail communication to us.
Prudential Bache Commodities, LLC, Prudential Bache Securities, LLC,
Bache Commodities Limited and Bache Commodities (Hong Kong) Limited are
affiliates of Prudential Financial, Inc., which is headquartered in the
United States. Bache Commodities Limited is authorized and regulated by
the Financial Services Authority.
If you have received this communication in error, please notify the
sender immediately by replying to the message and delete it from your
system. If you do not wish to receive further e-mail from us, please
send an e-mail to do.not.[Email address protected] Thank you.
---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY To post a
dba job: http://jobs.lazydba.com To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html
************** IMPORTANT MESSAGE *****************************
This e-mail message is intended only for the addressee(s) and contains information which may be
confidential.
If you are not the intended recipient please advise the sender by return email, do not use or
disclose the contents, and delete the message and any attachments from your system. Unless
specifically indicated, this email does not constitute formal advice or commitment by the sender
or the Commonwealth Bank of Australia (ABN 48 123 123 124) or its subsidiaries.
We can be contacted through our web site: commbank.com.au.
If you no longer wish to receive commercial electronic messages from us, please reply to this
e-mail by typing Unsubscribe in the subject line.
**************************************************************
---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY
To post a dba job: http://jobs.lazydba.com
To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html
MS Sql Server LazyDBA home page