Click here to Skip to main content
12,693,757 members (36,530 online)
Rate this:
Please Sign up or sign in to vote.
See more: C#
in the out put i have date in the 28/1/2013 format.

i want to change the date format in to 28 jan.

how can i get the 28 jan format in ms access database not in sql.

i wanted in MSAccess database.

how can i do.

i try the below query is not working

select CONVERT(varchar(11), Sch_Date, 106) AS schDate, [Session],[Faculty_Code] from Tb_SCh_TIme_Table

from my above query what is the mistake i me. i tried but not get the 28 jan ouput.
Posted 31-Jan-13 20:50pm
Zoltán Zörgő 1-Feb-13 1:56am
This question is confusing. You tagged your question with c#, but you ask for some access solution. But if you use c#, why do you want to format your date field on database level?

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Use Format function:[^]

SELECT Format (Sch_Date, "dd\/mm\/yyyy")
FROM b_SCh_TIme_Table

Note the "\". You can omit it, but if you do, the system local could override it.

Use Format (D, "dd mmm") to get "28 jan" format.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.170118.1 | Last Updated 1 Feb 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100