SqlShare.com Logo
 
Skip Navigation Links
Home
Video List
Events
Classes
About Us
Login / Register
Subscribe RSS Feed 

Confio Ignite

CONVERT - Changing a Date to a String

Without a doubt the best practice is to store dates as dates (or something similar such as smalldatetime, date, or time) rather than strings. That works well as we write queries and do date based math, but users usually care more about the way the data looks than all the stuff we do behind the scenes. We'll show you how to use the 'style' parameter to control the formatting when you need to show date values in something other than the default date format.

Duration:
4 mins 51 secs
Skill Level:
100
Rating:
4.35 out of 5
Publish Date:
December 12, 2010
CONVERT - Changing a Date to a String You must be logged in to view this video.  
Bookmark and Share
 
1=Poor, 3=Good, 5=Excellent

About the Author

Image of Andy Warren
Andy Warren is a software trainer focusing on SQL Server, a member of the PASS Board of Directors, and a principal in this site - SQLShare.com.

References



Comments
Radhey Shyam on 12/14/2010
Good tutorial about date conversion !!

Tom Hamilton on 12/14/2010
Well done, merry Christmas

Sainey M. Drammeh on 12/14/2010
Thank you Andy.

Nilesh on 12/14/2010
ok....

Don Nesbitt on 12/14/2010
I've looked for this kind of information often and seldom found it. This is staight-forward, easy to understand and includes additional references.

Salman Hameed on 12/14/2010
I already knew it, but very good explanation.

Faisal Lodhi on 12/14/2010
Learned SOmething New today...thanks

Bridget on 12/14/2010
useful, thanks

Diana Dee on 12/14/2010
Have you said somewhere that varchar or char without a length specified defaults to (1) a length of 1 if used in a column or variable definition, or (2) a length of 30 if used in CAST or CONVERT ?

Leonard Peoples on 12/14/2010
Very helpful

FELIX on 12/21/2010
Excellent Video!

Leon on 12/29/2010
Learned something. Didnot know about the parameter. tHx. Advice: when you show the result I often want to look back to the command in the input pane, but this is often not visible because it is underneath the output pane. Could you consider having the command visible all the time?

Maurice Ivory on 7/18/2011
Yes I enjoyed the lesson, I will try out some of the different formats.

mahaboob on 2/14/2012
very good video. thank you



Must Be Logged In
 

How Do I Become a Video Author? |  Newsletter History

Copyright © Fourdeuce, Inc., 2005-2009. All Rights Reserved | Privacy Policy | Terms & Conditions