i have a column in my database called AddedDate with the data type "date". when i select the whole row from the database, date AND TIME appear and i don't want the time to appear. How can i prevent that? Can someone please help me with that?
The only database that I can readily think of where the date
data type has a time component is Oracle.
In Oracle, you can either truncate the date or convert to a string:
select trunc(datecol)
select to_char(datecol, 'YYYY-MM-DD')
These will remove the time component or set it to midnight.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.