Drop Table

Support Forum for database administrators and web based access to important newsgroups related to databases
Register on Database Support Forum Edit your profileCalendarFind other Database Support forum membersFrequently Asked QuestionsSearch this forum -> 
For Database admins: Free Database-related Magazines Now Free shipping to Texas


Post New Thread










Thread
Author

Date Format as British
Hi All,

I want to set Date format as British (i.e. dd/MM/yyyy 30/11/2005) in my
Database. What I will have to do for this.

TIA



Report this thread to moderator Post Follow-up to this message
Old Post
Kamal Ahmed
11-30-05 12:23 PM


Re: Date Format as British
hi Kamal,
Kamal Ahmed  wrote:
> Hi All,
>
> I want to set Date format as British (i.e. dd/MM/yyyy 30/11/2005) in
> my Database. What I will have to do for this.
>
this "setting" is login's related, that's to say it depend on the login's
language property, but it can be set using
SET DATEFROMAT xxx
(http://msdn.microsoft.com/library/d.../>
et_052s.asp)
for input...

please have a look at http://www.karaszi.com/SQLServer/info_datetime.asp
too..
--
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtm        http://italy.mvps.org
DbaMgr2k ver 0.16.0  -  DbaMgr ver 0.61.0
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
--------- remove DMO to reply



Report this thread to moderator Post Follow-up to this message
Old Post
Andrea Montanari
11-30-05 12:23 PM


RE: Date Format as British
Hopefully following posting can help you:

http://www.microsoft.com/technet/co...r />
96A551&ca
tlist=328BAFD2-1A81-4558-B1DE-B6EB49F31B7E&dglist=&ptlist=&exp=&sloc=en-us

"Kamal Ahmed" wrote:

> Hi All,
>
> I want to set Date format as British (i.e. dd/MM/yyyy 30/11/2005) in my
> Database. What I will have to do for this.
>
> TIA
>
>
>

Report this thread to moderator Post Follow-up to this message
Old Post
Absar Ahmad
11-30-05 12:23 PM


Re: Date Format as British
Kamal Ahmed  wrote:
> Hi All,
>
> I want to set Date format as British (i.e. dd/MM/yyyy 30/11/2005) in my
> Database.

Why? DATEFORMAT is set in each connection so the database setting is
pretty redundant. Best practice is to ignore the DATEFORMAT setting and
write code that performs correctly however this may be set. Crucially
this means that any hard-coded dates should be coded in ISO rather than
local format:

'YYYYMMDD'
or
'YYYY-MM-DDThh:mm:ss'
or
'YYYY-MM-DDThh:mm:ss.mmm'

All other date values should be handled as DATETIME or SMALLDATETIME
(which are unaffected by the format setting) or converted from strings
using the CONVERT style property.

--
David Portas
SQL Server MVP
--


Report this thread to moderator Post Follow-up to this message
Old Post
David Portas
11-30-05 12:23 PM


Sponsored Links





Last Thread Next Thread
Post New Thread

MS SQL Server archive

Show a Printable Version Email This Page to Someone! Receive updates to this thread
Microsoft SQL Server
Access database support
PostgreSQL Replication
SQL Server ODBC
FoxPro Support
PostgreSQL pgAdmin
SQL Server Clustering
MySQL ODBC
Web Applications with dBASE
SQL Server CE
MySQL++
Sybase Database Support
MS SQL Full Text Search
PostgreSQL Administration
SQL Anywhere support
DB2 UDB Database
Paradox Database Support
Filemaker Database
Berkley DB
SQL 2000/2000i database
ASE Database
Forum Jump:
All times are GMT. The time now is 07:27 PM.

 
Mobile devices forum | Database support forum archive




Copyrights DropTable.com Database Support Forum 2004 - 2006