Discussion:
Retrieving datetime date into perl.
Lenga, Yair
2008-12-29 13:27:05 UTC
Permalink
Hi,

I apologize for posting a questions that is only 50% related to Sybase.

I'm working on a module that has to retrieve and process datetime from
Sybase. My problem is that I deal with financial data, which extended
beyond 2037 - and I can not use standard Perl measure for time (seconds
past 1970) due to 32 bit overflow.

Does anyone know of a good way to handle this problem. Ideally, I'm
looking for a module that will
- Parse dates from the format provided by DBD::Sybase.
- Allow for basic math of the dates - same as Sybase dateadd, datediff,
datepart, ...
- Support formatting similar to strftime.
- Hopefully, something that can handle dates, as well as sub-seconds
time stamp - so I have one solution for all my date processing.

Thanks,
Yair Lenga
m***@jpmchase.com
2008-12-29 13:54:24 UTC
Permalink
I think there are a number of Date related modules on CPAN - one that
comes to mind is DateCalc (I think).

Michael





"Lenga, Yair " <***@citi.com>
Sent by: owner-sybperl-***@peppler.org
12/29/2008 02:27 PM

To
<sybperl-***@peppler.org>
cc

Subject
Retrieving datetime date into perl.






Hi,

I apologize for posting a questions that is only 50% related to Sybase.

I'm working on a module that has to retrieve and process datetime from
Sybase. My problem is that I deal with financial data, which extended
beyond 2037 - and I can not use standard Perl measure for time (seconds
past 1970) due to 32 bit overflow.

Does anyone know of a good way to handle this problem. Ideally, I'm
looking for a module that will
- Parse dates from the format provided by DBD::Sybase.
- Allow for basic math of the dates - same as Sybase dateadd, datediff,
datepart, ...
- Support formatting similar to strftime.
- Hopefully, something that can handle dates, as well as sub-seconds
time stamp - so I have one solution for all my date processing.

Thanks,
Yair Lenga





-----------------------------------------
This communication is for informational purposes only. It is not
intended as an offer or solicitation for the purchase or sale of
any financial instrument or as an official confirmation of any
transaction. All market prices, data and other information are not
warranted as to completeness or accuracy and are subject to change
without notice. Any comments or statements made herein do not
necessarily reflect those of JPMorgan Chase & Co., its subsidiaries
and affiliates.

This transmission may contain information that is privileged,
confidential, legally privileged, and/or exempt from disclosure
under applicable law. If you are not the intended recipient, you
are hereby notified that any disclosure, copying, distribution, or
use of the information contained herein (including any reliance
thereon) is STRICTLY PROHIBITED. Although this transmission and any
attachments are believed to be free of any virus or other defect
that might affect any computer system into which it is received and
opened, it is the responsibility of the recipient to ensure that it
is virus free and no responsibility is accepted by JPMorgan Chase &
Co., its subsidiaries and affiliates, as applicable, for any loss
or damage arising in any way from its use. If you received this
transmission in error, please immediately contact the sender and
destroy the material in its entirety, whether in electronic or hard
copy format. Thank you.

Please refer to http://www.jpmorgan.com/pages/disclosures for
disclosures relating to UK legal entities.
Jason L. Froebe
2008-12-29 17:58:13 UTC
Permalink
Check out Date::Manip :)

Jason L. Froebe


Tech log http://www.froebe.net/blog
MyDatabases (free) magazine: http://froebe.net/blog/category/databases/my-databases/
Froebe Fibers http://www.froebe-fibers.com


The opinions expressed within are the sole rantings of a raving lunatic and in no way reflect the rantings, fits, tantrums, errors, corrections, allocutions, or aimless thoughts of Sybase or its employees or of TeamSybase or ISUG. Any resemblence to reasonable thought, or any official or published opinion of Sybase, TeamSybase or ISUG is merely coincidental, and should be totally ignored.




----- Original Message ----
From: "***@jpmchase.com" <***@jpmchase.com>
To: "Lenga, Yair " <***@citi.com>
Cc: sybperl-***@peppler.org
Sent: Monday, December 29, 2008 7:54:24 AM
Subject: Re: Retrieving datetime date into perl.

I think there are a number of Date related modules on CPAN - one that
comes to mind is DateCalc (I think).

Michael





"Lenga, Yair " <***@citi.com>
Sent by: owner-sybperl-***@peppler.org
12/29/2008 02:27 PM

To
<sybperl-***@peppler.org>
cc

Subject
Retrieving datetime date into perl.






Hi,

I apologize for posting a questions that is only 50% related to Sybase.

I'm working on a module that has to retrieve and process datetime from
Sybase. My problem is that I deal with financial data, which extended
beyond 2037 - and I can not use standard Perl measure for time (seconds
past 1970) due to 32 bit overflow.

Does anyone know of a good way to handle this problem. Ideally, I'm
looking for a module that will
- Parse dates from the format provided by DBD::Sybase.
- Allow for basic math of the dates - same as Sybase dateadd, datediff,
datepart, ...
- Support formatting similar to strftime.
- Hopefully, something that can handle dates, as well as sub-seconds
time stamp - so I have one solution for all my date processing.

Thanks,
Yair Lenga





-----------------------------------------
This communication is for informational purposes only. It is not
intended as an offer or solicitation for the purchase or sale of
any financial instrument or as an official confirmation of any
transaction. All market prices, data and other information are not
warranted as to completeness or accuracy and are subject to change
without notice. Any comments or statements made herein do not
necessarily reflect those of JPMorgan Chase & Co., its subsidiaries
and affiliates.

This transmission may contain information that is privileged,
confidential, legally privileged, and/or exempt from disclosure
under applicable law. If you are not the intended recipient, you
are hereby notified that any disclosure, copying, distribution, or
use of the information contained herein (including any reliance
thereon) is STRICTLY PROHIBITED. Although this transmission and any
attachments are believed to be free of any virus or other defect
that might affect any computer system into which it is received and
opened, it is the responsibility of the recipient to ensure that it
is virus free and no responsibility is accepted by JPMorgan Chase &
Co., its subsidiaries and affiliates, as applicable, for any loss
or damage arising in any way from its use. If you received this
transmission in error, please immediately contact the sender and
destroy the material in its entirety, whether in electronic or hard
copy format. Thank you.

Please refer to http://www.jpmorgan.com/pages/disclosures for
disclosures relating to UK legal entities.
Matthew Persico
2009-01-13 05:43:17 UTC
Permalink
Post by Jason L. Froebe
Check out Date::Manip :)
From experience, be careful. Some of thse are REALLY HEAVY modules and
if you create hundreds or thousands of them, you WILL slow down your
program appreciably. Test and benchmark first.
Post by Jason L. Froebe
Jason L. Froebe
Tech log http://www.froebe.net/blog
MyDatabases (free) magazine: http://froebe.net/blog/category/databases/my-databases/
Froebe Fibers http://www.froebe-fibers.com
The opinions expressed within are the sole rantings of a raving lunatic and in no way reflect the rantings, fits, tantrums, errors, corrections, allocutions, or aimless thoughts of Sybase or its employees or of TeamSybase or ISUG. Any resemblence to reasonable thought, or any official or published opinion of Sybase, TeamSybase or ISUG is merely coincidental, and should be totally ignored.
----- Original Message ----
Sent: Monday, December 29, 2008 7:54:24 AM
Subject: Re: Retrieving datetime date into perl.
I think there are a number of Date related modules on CPAN - one that
comes to mind is DateCalc (I think).
Michael
12/29/2008 02:27 PM
To
cc
Subject
Retrieving datetime date into perl.
Hi,
I apologize for posting a questions that is only 50% related to Sybase.
I'm working on a module that has to retrieve and process datetime from
Sybase. My problem is that I deal with financial data, which extended
beyond 2037 - and I can not use standard Perl measure for time (seconds
past 1970) due to 32 bit overflow.
Does anyone know of a good way to handle this problem. Ideally, I'm
looking for a module that will
- Parse dates from the format provided by DBD::Sybase.
- Allow for basic math of the dates - same as Sybase dateadd, datediff,
datepart, ...
- Support formatting similar to strftime.
- Hopefully, something that can handle dates, as well as sub-seconds
time stamp - so I have one solution for all my date processing.
Thanks,
Yair Lenga
-----------------------------------------
This communication is for informational purposes only. It is not
intended as an offer or solicitation for the purchase or sale of
any financial instrument or as an official confirmation of any
transaction. All market prices, data and other information are not
warranted as to completeness or accuracy and are subject to change
without notice. Any comments or statements made herein do not
necessarily reflect those of JPMorgan Chase & Co., its subsidiaries
and affiliates.
This transmission may contain information that is privileged,
confidential, legally privileged, and/or exempt from disclosure
under applicable law. If you are not the intended recipient, you
are hereby notified that any disclosure, copying, distribution, or
use of the information contained herein (including any reliance
thereon) is STRICTLY PROHIBITED. Although this transmission and any
attachments are believed to be free of any virus or other defect
that might affect any computer system into which it is received and
opened, it is the responsibility of the recipient to ensure that it
is virus free and no responsibility is accepted by JPMorgan Chase &
Co., its subsidiaries and affiliates, as applicable, for any loss
or damage arising in any way from its use. If you received this
transmission in error, please immediately contact the sender and
destroy the material in its entirety, whether in electronic or hard
copy format. Thank you.
Please refer to http://www.jpmorgan.com/pages/disclosures for
disclosures relating to UK legal entities.
--
Matthew O. Persico
Loading...