You could do it either way. I find that storing it all in one
string is convenient when you need to display it alot, but if
you need to make extensive calculations off the date, then it's
probably better to store the seconds separately. I've also found
that sometimes it's easier to grab the date in two different formats,
then stick it together in a way that is easier to work with. (Like
using the month and day of one, then using the 4 digit year, so you
end up with a string like 08292000, then you can divide it up any
way you like.
-Rus
>-----Original Message-----
>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, August 29, 2000 10:43 AM
>To: Palm Developer Forum
>Subject: dates in a database
>
>
>I'm something of a newbie at this, so I apologize if I'm
>wasting time with a basic question...
>(but here goes anyway ;-)
>I am writing an app that stores records in a database.
>Each record includes a date. I'me using the
>DateTimeType. What's the best way to store that date in
>my record? Should I pack up the year, month and day as
>CharPtr's, or should I store the numebr of seconds since
>my grandmother was born (1/1/1904... not really)? What
>other options might I have that I haven't thought of?
>
>Thanks,
>Lauren
>
>--
>For information on using the Palm Developer Forums, or to
>unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/