|
Posted by Gordon Burditt on 07/21/05 02:02
In article <ha6dnUleXsh-S0PfRVn-pA@comcast.com>,
Shelly <sheldonlg.news@asap-consult.com> wrote:
>
>"Gordon Burditt" <gordonb.0zad4@burditt.org> wrote in message
>news:11dtl64ik972072@corp.supernews.com...
>> >Here is what I have (part, at least)
>>>
>>> echo $dbResult[$i]["sender"] . ' ' . $dbResult[$i]["subject"] . ' ' .
>>> $dbResult[$i]["timestamp"] . " " .
>>> date("M j, Y, g:i a", $dbResult[$i]["timestamp"]) . '<br>';
>>>
>>>
>>>Here is what it puts out (formatted here to make it easier for you to
>>>read)
>>>
>>>NumEmail = 3
>>>sheldonlg Third message 20050720060604 Jan 18, 2038, 9:14 pm
>>>sheldonlg Long text 20050719200450 Jan 18, 2038, 9:14 pm
>>>sheldonlg est 20050719200127 Jan 18, 2038, 9:14 pm
>>>
>>>
>>>Why, for different timestamps, is it different?
>>
>> Is *WHAT* different? The subject line?
>> The last field you printed ISN'T different for the 3 messages.
>> Did you leave the word NOT out of the question?
>
>Yes, I did leave out NOT.
>
>> date() takes a UNIX timestamp as a second argument. What you have
>> printed in the third column (and fed as a second argument to date()
>> is not a UNIX timestamp and won't fit in 32 bits, so it overflowed.
>
>If that is not the unix timestamp, but is the timestamp that appears when I
>insert in the MySQL database, how do I get the unix timestamp from that?
select unix_timestamp(stamp) from wristwatch;
Gordon L. Burditt
Navigation:
[Reply to this message]
|