• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Recording and looking up dates, when day-wide precision is required
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Recording and looking up dates, when day-wide precision is required


  • Subject: Re: Recording and looking up dates, when day-wide precision is required
  • From: Lachlan Deck <email@hidden>
  • Date: Tue, 30 Dec 2008 18:12:40 +1100

On 25/12/2008, at 6:54 AM, Ken Anderson wrote:

What I do is build a GregorianCalendar using the user's local timezone, extract the day/month/year using the get method of GregorianCalendar, then construct a new date using GMT.

new NSTimestamp(date) does the same thing (assuming you've used a formatter in the user's timezone) :-)


When I take that date out of the database, I use a date formatter set to GMT, and I always get the date the user input, regardless of what timezone they were in.

Again, NSTimestamp is already GMT unless you're saying you're using a different column type.


with regards,
--

Lachlan Deck

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Recording and looking up dates, when day-wide precision is required (From: Florijan Stamenkovic <email@hidden>)
 >Re: Recording and looking up dates, when day-wide precision is required (From: Lachlan Deck <email@hidden>)
 >Re: Recording and looking up dates, when day-wide precision is required (From: Florijan Stamenkovic <email@hidden>)
 >Re: Recording and looking up dates, when day-wide precision is required (From: Lachlan Deck <email@hidden>)
 >Re: Recording and looking up dates, when day-wide precision is required (From: Florijan Stamenkovic <email@hidden>)
 >Re: Recording and looking up dates, when day-wide precision is required (From: Ken Anderson <email@hidden>)

  • Prev by Date: Re: OpenBase & WebObjects for scaling
  • Next by Date: Re: Recording and looking up dates, when day-wide precision is required
  • Previous by thread: Re: Recording and looking up dates, when day-wide precision is required
  • Next by thread: Re: Recording and looking up dates, when day-wide precision is required
  • Index(es):
    • Date
    • Thread