On 20/6/01 at 3:44 pm, [EMAIL PROTECTED] (Michael Fowler) wrote:
Thank for your help, I'll try some of it out and let you know. The data
comes from a mainframe system and going to be loaded into MS SQL Server
database. I am really impressed by Perl, it can do easy things so
quickly.
>
> > my @fields = unpack($template, $_);
>
> What is $template, anyhow?
This is the format of the fixed lenght record as 'a6
a4
a4
a4
a10
a3
a20
a65
a13
a13
a13
a19
a13
a3
';
I am putting tabs between the fields and then changing the a13 which is
a tso overpunch to its decimal equiv, e.g. 1234} means -123.40 .
As I hinted, my code is very procedural as I am not used to Perl yet. In
terms of timimgs, it is still nearly 50% faster as is but that may not
be enough to persuade the mangers to use it instead of Visual Basic,
which is by all accounts much harder to maintain for this type of
processing, but VB is the standard so I have an uphill struggle :-(
Thanks again,
Regards
Mark Bedish
Surrey,UK