I need solution as a query.
Since we have no idea of the structure of your database, its tables, or indeed the field you are interested in then it is impossible to provide it. However, there are standard library functions that will convert a timestamp into a character string, depending on the format and value of the timestamp. See
https://msdn.microsoft.com/en-us/library/w4ddyt9h.aspx[
^] for details.