I looked into but couldn't find succifient info.
Where is to best place for data conversion including performance consideration?In data query side or in web server side?
For instance:My database contains datetime fields and i am showing them in web page with different format.I can do it in database queries like:
CONVERT(VARCHAR, StartDate, 1) --mssql
DATE_FORMAT(last_update, '%d/%m/%y') -- mysql
TO_CHAR(sysdate, 'dd/mm/yy'); -- oracle
or in web application codes:
date_format($date, 'd/m/y'); /*php*/
(new SimpleDateFormat("dd/MM/yy")).parse(date) /*jsp*/
#DateFormat(date, 'dd/mm/yy')# <!---coldfusion--->
date.ToString("dd/MM/yy") //asp.net
of course in web codes date variable populated with date/time values without conversion in db queries. Also worth to mention that data extraction results have very much records.
Note:I am not professional with above platform/languages, wrote them to attract more answerers to generalize the question.Currently I am interested in cf/mssql.