CONVERT(varchar, mydate, 103)
not tested
Laurent Fontaine
Sr Web Developer
American Power Conversion
Level 13, 65 Berry Street
North Sydney, NSW 2060
AUSTRALIA
tel: +61 2 8923 9339
@: [EMAIL PROTECTED]
"James MacPherson"
<jmacpherson@creativefactory. To: "CFAussie Mailing
List" <[EMAIL PROTECTED]>
com.au> cc:
Sent by: Subject: [cfaussie] RE:
pick record with same date irnoring time
[EMAIL PROTECTED]
emon.com.au
21/02/2003 04:33 PM
Please respond to "CFAussie
Mailing List"
Okies, well the code I sent will do the date but (from your example) will
give this result:
21/2/2003
20/2/2003
rather than:
21/02/2003
20/02/2003
if that's important then I'm not sure how to force sql server to give you
the extra 0's
- James
-----Original Message-----
From: Balaji [mailto:[EMAIL PROTECTED]]
Sent: Friday, 21 February 2003 15:48
To: CFAussie Mailing List
Subject: [cfaussie] RE: pick record with same date irnoring time
Hi James,
I want to pick all distinct dates ignoring time..
there could be something like this.
21/02/2003 10:00:03
21/02/2003 12:06:04
20/02/2003 01:51:22
20/02/2003 01:57:22
I want this result.
21/02/2003
20/02/2003
--Bal
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of James
MacPherson
Sent: Friday, February 21, 2003 3:52 PM
To: CFAussie Mailing List
Subject: [cfaussie] RE: pick record with same date irnoring time
try something like:
SELECT *
FROM tablename
WHERE CONVERT(nvarchar(2), DAY(tablename.column)) + '/' +
CONVERT(nvarchar(2), MONTH(tablename.column)) + '/' + CONVERT(nvarchar(4),
YEAR tablename.column)) = 'date goes here'
-----Original Message-----
From: Balaji [mailto:[EMAIL PROTECTED]]
Sent: Friday, 21 February 2003 15:38
To: CFAussie Mailing List
Subject: [cfaussie] pick record with same date irnoring time
Hi,
I want to pick records from a table with distinct dates ignoring time.
suggestions pls..
--Bal
---
You are currently subscribed to cfaussie as:
[EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as:
[EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
MX Downunder AsiaPac DevCon - http://mxdu.com/