| List: | General Discussion | « Previous MessageNext Message » | |
| From: | (Hal | Date: | February 5 2012 5:29pm |
| Subject: | Re: how to changing default '-' character in Datetime in MySQL? | ||
| View as plain text | |||
>>>> 2012/02/04 19:13 -0800, Rajeev Prasad >>>>
MySQL datetime field type keeps data as: YYYY-MM-DD HH:mm:SS is there a way to store this
data as: YYYY/MM/DD HH:mm:SS or going much further (optionally) can we store as:
MM/DD/YYYY HH:mm:SS ? if not then whats the best way to reformat the cell value from
YYYY-MM-DD to MM/DD/YYY
<<<<<<<<
That is MySQL s string format, and that is what you get. That said, there is a function
DATE_FORMAT (look it up) that lets one change its look. Its format argument is quite
ugly.
| Thread | ||
|---|---|---|
| • how to changing default '-' character in Datetime in MySQL? | Rajeev Prasad | 5 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | hsv | 5 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | Michael Dykman | 6 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | Rajeev Prasad | 6 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | Michael Dykman | 6 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | Peter Brawley | 6 Feb |
| • Re: how to changing default '-' character in Datetime in MySQL? | hsv | 6 Feb |
