Mailing List Archive

soap story update cover date
I'm trying to update the cover date on a set of stories via soap by
exporting, regexing, then updating. This appears to work without error, but
when I look at the stories through the web interface the cover dates are
off. The year is 1 less, the day is 1 less, and the hour is 19:00:00 when it
should be 00:00:00. However, when I look up the same story in the
story_instance table it has the correct updated date.

I have no idea what's happening. Am I formatting my date incorrectly? Is it
being interpreted in a way I didn't expect? Is timezone a factor? I checked
bric's date settings and they look reasonable (Eastern Time). What am I
doing wrong?

My xml looks as such:

...
<cover_date>2002-01-01T00:00:00Z</cover_date>
...

which produces a cover date of:

2001-12-31 19:00:00


-- - - - - -
-

-
ryan
RE: soap story update cover date [ In reply to ]
What is your timezone setting in the UI? Midnight Jan 1 of 02 GMT is 7 PM Dec 31st EST.

> -----Original Message-----
> From: Ryan O'Toole [mailto:rotoole@gmail.com]
> Sent: Saturday, July 18, 2009 1:53 PM
> To: bricolage-devel
> Subject: soap story update cover date
>
> I'm trying to update the cover date on a set of stories via soap by
> exporting, regexing, then updating. This appears to work without error,
> but
> when I look at the stories through the web interface the cover dates
> are
> off. The year is 1 less, the day is 1 less, and the hour is 19:00:00
> when it
> should be 00:00:00. However, when I look up the same story in the
> story_instance table it has the correct updated date.
>
> I have no idea what's happening. Am I formatting my date incorrectly?
> Is it
> being interpreted in a way I didn't expect? Is timezone a factor? I
> checked
> bric's date settings and they look reasonable (Eastern Time). What am I
> doing wrong?
>
> My xml looks as such:
>
> ...
> <cover_date>2002-01-01T00:00:00Z</cover_date>
> ...
>
> which produces a cover date of:
>
> 2001-12-31 19:00:00
>
>
> -- - - - - -
> -
>
> -
> ryan
Re: soap story update cover date [ In reply to ]
eastern time.

--
mobile ryan

On Jul 18, 2009, at 3:27 PM, Adam Wilson <adam@RFXTechnologies.com>
wrote:

> What is your timezone setting in the UI? Midnight Jan 1 of 02 GMT
> is 7 PM Dec 31st EST.
>
>> -----Original Message-----
>> From: Ryan O'Toole [mailto:rotoole@gmail.com]
>> Sent: Saturday, July 18, 2009 1:53 PM
>> To: bricolage-devel
>> Subject: soap story update cover date
>>
>> I'm trying to update the cover date on a set of stories via soap by
>> exporting, regexing, then updating. This appears to work without
>> error,
>> but
>> when I look at the stories through the web interface the cover dates
>> are
>> off. The year is 1 less, the day is 1 less, and the hour is 19:00:00
>> when it
>> should be 00:00:00. However, when I look up the same story in the
>> story_instance table it has the correct updated date.
>>
>> I have no idea what's happening. Am I formatting my date incorrectly?
>> Is it
>> being interpreted in a way I didn't expect? Is timezone a factor? I
>> checked
>> bric's date settings and they look reasonable (Eastern Time). What
>> am I
>> doing wrong?
>>
>> My xml looks as such:
>>
>> ...
>> <cover_date>2002-01-01T00:00:00Z</cover_date>
>> ...
>>
>> which produces a cover date of:
>>
>> 2001-12-31 19:00:00
>>
>>
>> -- - - - - -
>> -
>>
>> -
>> ryan
Re: soap story update cover date [ In reply to ]
hmm, makes sense. the db date is GMT so it can be adjusted for the
time zone pref.

if i want an east coast time stamp i need to offset the hour
accordingly. duh.

guess new years day was a weird date to encounter this problem.

--
mobile ryan

On Jul 18, 2009, at 3:27 PM, Adam Wilson <adam@RFXTechnologies.com>
wrote:

> What is your timezone setting in the UI? Midnight Jan 1 of 02 GMT
> is 7 PM Dec 31st EST.
>
>> -----Original Message-----
>> From: Ryan O'Toole [mailto:rotoole@gmail.com]
>> Sent: Saturday, July 18, 2009 1:53 PM
>> To: bricolage-devel
>> Subject: soap story update cover date
>>
>> I'm trying to update the cover date on a set of stories via soap by
>> exporting, regexing, then updating. This appears to work without
>> error,
>> but
>> when I look at the stories through the web interface the cover dates
>> are
>> off. The year is 1 less, the day is 1 less, and the hour is 19:00:00
>> when it
>> should be 00:00:00. However, when I look up the same story in the
>> story_instance table it has the correct updated date.
>>
>> I have no idea what's happening. Am I formatting my date incorrectly?
>> Is it
>> being interpreted in a way I didn't expect? Is timezone a factor? I
>> checked
>> bric's date settings and they look reasonable (Eastern Time). What
>> am I
>> doing wrong?
>>
>> My xml looks as such:
>>
>> ...
>> <cover_date>2002-01-01T00:00:00Z</cover_date>
>> ...
>>
>> which produces a cover date of:
>>
>> 2001-12-31 19:00:00
>>
>>
>> -- - - - - -
>> -
>>
>> -
>> ryan
Re: soap story update cover date [ In reply to ]
On Jul 18, 2009, at 9:13 PM, Ryan O'Toole wrote:

> hmm, makes sense. the db date is GMT so it can be adjusted for the
> time zone pref.
>
> if i want an east coast time stamp i need to offset the hour
> accordingly. duh.
>
> guess new years day was a weird date to encounter this problem.

Or else make the TZ "America/New_York" instead of "Z".

Best,

David
Re: soap story update cover date [ In reply to ]
OK, I was thinking of asking about the Z. I was not sure what it meant. My
regex just kept the same format that bric originally spit out. I assumed it
was an eastern time stamp, since that was how the preference was set.

ryan

On Sun, Jul 19, 2009 at 5:36 PM, David E. Wheeler <david@kineticode.com>wrote:

> On Jul 18, 2009, at 9:13 PM, Ryan O'Toole wrote:
>
> hmm, makes sense. the db date is GMT so it can be adjusted for the time
>> zone pref.
>>
>> if i want an east coast time stamp i need to offset the hour accordingly.
>> duh.
>>
>> guess new years day was a weird date to encounter this problem.
>>
>
> Or else make the TZ "America/New_York" instead of "Z".
>
> Best,
>
> David
>
Re: soap story update cover date [ In reply to ]
On Jul 19, 2009, at 5:16 PM, Ryan O'Toole wrote:

> OK, I was thinking of asking about the Z. I was not sure what it
> meant. My
> regex just kept the same format that bric originally spit out. I
> assumed it
> was an eastern time stamp, since that was how the preference was set.

Z is Zulu time, same as UTC. SOAP always exports dates and times in UTC.

Best,

David