problem simulate timedate for my database
528215Dec 10 2006 — edited Dec 10 2006Hi
I want to simulate sql table that have fields like this(int id,varchar name,datetime timein)
for simulate this situation I defined database and defined structure like this:
struct TimeDate{
int year;
short month;
short day;
short hour;
short minute;
short second;
};
typedef struct session {
int ID;
char *name;
struct TimeDate Timein;
}SESSION;
is this methood suitable for define datetime or not?
is it good to store unixtime in the database or this method ?
thanks
regards
saeed