Store time and date separably in a mysql database using default values -
in mysql database table have 2 columns called "date" , "time". "date" datatype set datetime , "time" datatype set timestamp. want store date in "date" column , store time in "time" column. table name "loans".i'm not in sql querying. please show me how that.
and have problems time zones. want convert database time format utc -5:00 (us time).how can without change pc time ?
separating date , time same event bad idea. go storing in simple datetime field.
but can this
give date field type date
(not datetime) , time field type time
(yes exists , not timestamp)
now allow store date in yyyy-mm-dd
, time in hh:mm:ss
to set time zone of mysql server can use one
Comments
Post a Comment