[8441] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 2058 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Mar 9 15:17:17 1998

Date: Mon, 9 Mar 98 12:00:33 -0800
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Mon, 9 Mar 1998     Volume: 8 Number: 2058

Today's topics:
        ANNOUNCE: "Bit::Vector" 5.1 (final release) <sb@sdm.de>
        ANNOUNCE: Math-MagicSquare 1.00 module <pivari@geocities.com>
        ANNOUNCE: MHonArc v2.2.0 (Earl Hood)
        ANNOUNCE: nsapi_perl/Netscape::Server v0.22 available <bsugars@canoe.ca>
        ANNOUNCE: VMS::Persona 1.01 (Dan Sugalski)
        ANNOUNCE: VMS::Priv 1.31 (Dan Sugalski)
        Announce: VMS::Process 1.04 (Dan Sugalski)
        ANNOUNCE: Xbase/DBF record manager <agraham@usa.net>
    Re: error??? <merlyn@stonehenge.com>
    Re: gzipped tar perl manual <barnett@houston.Geco-Prakla.slb.com>
        Help, command not being executed, stumped (A. P. Beaudoin)
        IndexMaker 5.0: an index.html maker from PDF,HTML,VRML  <pivari@geocities.com>
        MS Excel -> HTML <schwartz@cs.tu-berlin.de>
        ObjStore 1.30 <pritikin@mindspring.com>
        OUT OF MEMORY??? <aahanson@students.uiuc.edu>
        Parsing environment variables (Ed Avis)
    Re: Perl <-> Sybase mpeppler@mbay.net
        Perl Hash question <gregp@home.com>
    Re: Perl Hash question <jdf@pobox.com>
        PERL32 / mail / NT40 (Edwin J. van Stam)
    Re: PerlW32 on NT, cannot use > or |  why? <dcarr@ivation.com>
        Please Disregard this old thing <lovegod@earthling.net>
        Plot.pm - Front end to GD.pm for plotting two dimension <sanford@halcyon.com>
    Re: Problem with "goto" in Perl <jdporter@min.net>
    Re: random numbers? (Abigail)
        Relational arrays (Baboulen)
        Set::IntSpan 1.06 released - bug fix (Steven W McDougall)
        use Module vs. no Module ??? <jdporter@min.net>
    Re: Using perl to do what a spreadsheet does but with a (Abigail)
        Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 9 Mar 1998 19:00:48 GMT
From: Steffen Beyer <sb@sdm.de>
Subject: ANNOUNCE: "Bit::Vector" 5.1 (final release)
Message-Id: <6e1e90$494$1@news1.teleport.com>

I am glad to announce version 5.1 of the "Bit::Vector" module:

                    =====================================
                      Package "Bit::Vector" Version 5.1
                    =====================================

The package is available for download either from my web site at

                  http://www.engelschall.com/u/sb/download/

or from any CPAN (= "Comprehensive Perl Archive Network") mirror server:
(allow a few days for propagation if necessary)

                  http://www.perl.com/CPAN/authors/id/STBEY/

The package consists of a C library (designed for maximum efficiency)
which is the core of a Perl module (designed for maximum ease of use).

The C library is specifically designed so that it can be used stand-alone,
without Perl.


What does it do:
----------------

This module is useful for a large range of different tasks:

  -  For example for implementing sets and performing set operations
     (like union, difference, intersection, complement, check for subset
     relationship etc.),

  -  as a basis for many efficient algorithms, for instance the
     "Sieve of Erathostenes" (for calculating prime numbers),

     (The complexities of the methods in this module are usually either
      O(1) or O(n/b), where "b" is the number of bits in a machine word
      on your system.)

  -  for shift registers of arbitrary length (for example for cyclic
     redundancy checksums),

  -  to calculate "look-ahead", "first" and "follow" character sets
     for parsers and compiler-compilers,

  -  for graph algorithms,

  -  for efficient storage and retrieval of status information,

  -  for performing text synthesis ruled by boolean expressions,

  -  for "big integer" arithmetic with arbitrarily large integers,

  -  for manipulations of chunks of bits of arbitrary size,

  -  for bitwise processing of audio CD wave files,

  -  to convert formats of data files,

and more.

(A number of example applications is available from my web site at
http://www.engelschall.com/u/sb/download/.)

A large number of import/export methods allow you to access individual
bits, contiguous ranges of bits, machine words, arbitrary chunks of
bits, lists (arrays) of chunks of bits or machine words and a whole
bit vector at once (for instance for blockwrite/-read to and from
a file).

You can also import and export the contents of a bit vector in binary,
hexadecimal and decimal representation as well as ".newsrc" style
enumerations.

Note that this module is specifically designed for efficiency, which is
also the reason why its methods are implemented in C.

To further increase execution speed, the module doesn't use bytes as its
basic storage unit, but rather uses machine words, assuming that a machine
word is the most efficiently handled size of all scalar types on all
machines (that's what the ANSI C standard proposes and assumes anyway).

In order to achieve this, it automatically determines the number of bits
in a machine word on your system and then adjusts its internal configuration
constants accordingly.

The greater the size of this basic storage unit, the better the complexity
(= execution speed) of the methods in this module, but also the greater the
average waste of unused bits in the last word.

The range of available methods is exceptionally large for this kind of library;
in detail:

Version()                to_Bin()                 Divide()
Word_Bits()              from_Bin()               GCD()
Long_Bits()              to_Dec()                 Block_Store()
new()                    from_Dec()               Block_Read()
Shadow()                 to_Enum()                Word_Size()
Clone()                  from_Enum()              Word_Store()
Concat()                 Bit_Off()                Word_Read()
Concat_List()            Bit_On()                 Word_List_Store()
Size()                   bit_flip()               Word_List_Read()
Resize()                 bit_test()               Word_Insert()
Copy()                   Bit_Copy()               Word_Delete()
Empty()                  LSB()                    Chunk_Store()
Fill()                   MSB()                    Chunk_Read()
Flip()                   lsb()                    Chunk_List_Store()
Primes()                 msb()                    Chunk_List_Read()
Reverse()                rotate_left()            Index_List_Remove()
Interval_Empty()         rotate_right()           Index_List_Store()
Interval_Fill()          shift_left()             Index_List_Read()
Interval_Flip()          shift_right()            Union()
Interval_Reverse()       Move_Left()              Intersection()
Interval_Scan_inc()      Move_Right()             Difference()
Interval_Scan_dec()      Insert()                 ExclusiveOr()
Interval_Copy()          Delete()                 Complement()
Interval_Substitute()    increment()              subset()
is_empty()               decrement()              Norm()
is_full()                add()                    Min()
equal()                  subtract()               Max()
Lexicompare()            Negate()                 Multiplication()
Compare()                Absolute()               Closure()
to_Hex()                 Sign()                   Transpose()
from_Hex()               Multiply()


Important note:
---------------

Note again that the C library at the core of this module ("BitVector.c")
can also be used stand-alone (i.e., without Perl).

To do so, simply link the output file "BitVector.o" (which is produced
when you build this module or when you just compile "BitVector.c") with
your application.


Example applications:
---------------------

See the module "Set::IntegerRange" for an easy-to-use module for sets
of integers.

See the module "Math::MatrixBool" for an implementation of boolean
matrices.

(Both modules are also available from my web site or any CPAN server.)

A tool relying crucially on this "Bit::Vector" module is "Slice",
a tool for generating different document versions out of a single
master file, ruled by boolean expressions ("include english version
of text plus examples but not ...").

(See also http://www.engelschall.com/sw/slice/.)

This tool is itself part of another tool, "WML" ("Website Meta Language"),
which allows you to generate and maintain large web sites.

Among many other features, it allows you to define your own HTML tags which
will be expanded either at generation or at run time, depending on your
choice.

(See also http://www.engelschall.com/sw/wml/.)

Both tools are written by Ralf S. Engelschall.


Changes in version 5.1:
-----------------------

In version 5.1, systematic exception handling was added to "Vector.pm" so that
error conditions arising from method calls in overloaded operators do not show
error messages anymore pointing to the location in "Vector.pm" where the method
was called, but rather to the location in your application program where the
overloaded operator was used.


New features in version 5.0:
----------------------------

In version 5.0, the following new methods have been added:

  -  Word_Bits()
  -  Long_Bits()
  -  Concat()
  -  Concat_List()
  -  Primes()
  -  Reverse()
  -  Interval_Reverse()
  -  Interval_Copy()
  -  Interval_Substitute()
  -  Lexicompare()
  -  to_Bin()
  -  from_bin()
  -  to_Dec()
  -  from_dec()
  -  Bit_Copy()
  -  LSB()
  -  MSB()
  -  lsb()
  -  msb()
  -  Insert()
  -  Delete()
  -  add()
  -  subtract()
  -  Negate()
  -  Absolute()
  -  Sign()
  -  Multiply()
  -  Divide()
  -  GCD()
  -  Block_Store()
  -  Block_Read()
  -  Word_Size()
  -  Word_Store()
  -  Word_Read()
  -  Word_List_Store()
  -  Word_List_Read()
  -  Word_Insert()
  -  Word_Delete()
  -  Chunk_Store()
  -  Chunk_Read()
  -  Chunk_List_Store()
  -  Chunk_List_Read()
  -  Index_List_Remove()
  -  Index_List_Store()
  -  Index_List_Read()
  -  Transpose()

Please see the "Bit::Vector" man page (after installing this module)
for more details about these new methods.

The following methods have been re-implemented in C (instead of Perl):

  -  Version()
  -  Shadow()
  -  Clone()
  -  to_Enum()       (previously named "to_ASCII")
  -  from_enum()     (previously named "from_ASCII")

The following method has changed its behaviour:

  -  Compare()       (now assumes that bit vectors are SIGNED)

The following methods have been renamed:

  -  to_String()      -->    to_Hex()
  -  from_string()    -->    from_hex()
  -  to_ASCII()       -->    to_Enum()
  -  from_ASCII()     -->    from_enum()

(Aliases for the old names are still available but deprecated!)

And finally, the following methods are gone:

  -  lexorder()
  -  new_from_String()

A tool is available in the module's distribution to upgrade your existing
applications and to provide substitutes for the two methods that are gone.


Legal issues:
-------------

This package with all its parts is

Copyright (c) 1995, 1996, 1997, 1998 by Steffen Beyer.
All rights reserved.

This package is "Non-Profit-Ware" ("NP-ware").

You may use, copy, modify and redistribute it under
the terms of the "Non-Profit-License" (NPL).

Please refer to the file "NONPROFIT" in the package's
distribution for details!


Prerequisites:
--------------

Perl version 5.000 or higher, and an ANSI C compiler (!)
                                     ======


Author's note:
--------------

If you have any questions, suggestions or need any assistance, please
let me know!

Also, if there is anything you would like to do with this module which
the module doesn't allow yet, please let me know! If it fits the module's
overall concept, I'll implement it as soon as possible. Frequently this is
only a matter of a few days.

I hope you will find this module beneficial!

Yours,
--
    Steffen Beyer <sb@sdm.de> http://www.engelschall.com/u/sb/
     "There is enough for the need of everyone in this world,
      but not for the greed of everyone." - Mahatma Gandhi




------------------------------

Date: 9 Mar 1998 18:57:48 GMT
From: Fabrizio Pivari <pivari@geocities.com>
Subject: ANNOUNCE: Math-MagicSquare 1.00 module
Message-Id: <6e1e3c$42s$1@news1.teleport.com>

What is Math-MagicSquare module?
The first purpose of this PERL module is to help you to check your
Square, to answer these questions
Is it a Semimagic Square?
Is it a Magic Square?

The second purpose of this PERL module is to help you to print your
Square.
At the moment the method available is 'print' that prints the square on
STDOUT.
I'd like to add
- printhtml (to print the square in HTML format)
- pringif     (to print the square in a GIF image)
- prinpdf   (to print the square in PDF format)

What is a Magic Square?
Do you like Magic Square?
Do you want to know more information about Magic Square?
Try to visit

A very good introduction on Magic Square
http://www.astro.virginia.edu/~eww6n/math/MagicSquare.html

A whole collection of links and documents in Internet
http://www.pse.che.tohoku.ac.jp/~msuzuki/MagicSquare.html

A good collection of strange Magic Square
http://www.geocities.com/CapeCanaveral/Lab/3469/examples.html

The only Magic Square checker and gif maker in Internet (I think)
http://www.geocities.com/CapeCanaveral/Lab/3469/squaremaker.html

Where can I find it?
http://www.geocities.com/CapeCanaveral/Lab/3469/Math-MagicSquare.html
is the primary location
You also can find it at CPAN archive

Enjoy it!

Send me your suggestions.

--
Fabrizio Pivari
mailto:pivari@geocities.com
http://www.geocities.com/CapeCanaveral/Lab/3469/
Member of ANFACE Software
http://www.geocities.com/CapeCanaveral/Hangar/4794/






------------------------------

Date: 9 Mar 1998 18:56:14 GMT
From: ehood@medusa.acs.uci.edu (Earl Hood)
Subject: ANNOUNCE: MHonArc v2.2.0
Message-Id: <6e1e0e$41m$1@news1.teleport.com>
Keywords: MIME, HTML, Perl

Announcing release v2.2.0 of MHonArc.

What is MHonArc?

   MHonArc is a Perl program for converting e-mail messages as specified
   in RFC 822 and the MIME standard to HTML. MHonArc can perform the
   following tasks:
   
     * Convert MH mail folders or UUCP/Unix style mailboxes into an HTML
       mail archive.
     * Add or remove messages to an existing HTML mail archive generated
       by MHonArc.  
     * Convert a single message to HTML.
       
   Along with these tasks, MHonArc provides the following:
       
     * A main customizable index for mail messages archived.
     * A customizable thread index listing messages by thread.
     * Control over message formatting.
     * The ability to hook in your own custom message filters.


MIME support in MHonArc includes support for common media-types
(text/plain, text/html, text/enriched, multipart/mixed, image/gif, etc)
and non-ASCII extensions in message header text.  MHonArc is written
completely in Perl and provides mechanisms for hooking in custom
media-type filters and character set converters.

For more information and availability, see
(http://www.oac.uci.edu/indiv/ehood/mhonarc.html).

	--ewh
-- 
             Earl Hood              | University of California: Irvine
      ehood@medusa.acs.uci.edu      |      Electronic Loiterer
http://www.oac.uci.edu/indiv/ehood/ | Dabbler of SGML/WWW/Perl/MIME




------------------------------

Date: 9 Mar 1998 18:53:26 GMT
From: Benjamin Sugars <bsugars@canoe.ca>
Subject: ANNOUNCE: nsapi_perl/Netscape::Server v0.22 available
Message-Id: <6e1dr6$3r7$1@news1.teleport.com>

Greetings,

Version 0.22 of nsapi_perl has been added to the CPAN as:
  file: $CPAN/authors/id/BSUGARS/nsapi_perl-0.22.tar.gz
  size: 45217 bytes
   md5: d5ccb1733f7559ce0e9b5770a28bd74a

The latest version can always also be found at the nsapi_perl home
page located at:
  http://interact.canoe.ca/~bsugars/nsapi_perl.html

nsapi_perl is a set of Netscape Server API functions and Perl
extension modules that (in the spirit of mod_perl for Apache) embed a
Perl interpreter in a Netscape web server.  This allows you to program
to the Netscape server API in Perl rather than C.

The package includes the Netscape::Registry module which runs
unmodified Perl CGI programs from within the server process providing
large performance gains over regular CGI.

Major changes since version 0.20:
    - Fixed dynamic loading of Perl extension modules pulled in by
      nsapi_perl modules or Netscape::Registry scripts on Solaris.

    - The above fix may also help dynamic loading on IRIX and other
      Unices too, but we need to do more testing.  (BTW, dynamic
      loading on Win32 Just Works.)

    - Some improvements to Makefile.PL.

If you have any problems building nsapi_perl, please contact the
nsapi_perl mailing list, the address of which is found in the
distribution.  (I'd tell you here, but I don't want to invite spam.)

Thanks,
-Ben

--
Ben Sugars
Senior Webmaster,
CANOE Canadian Online Explorer,
http://www.canoe.ca/




------------------------------

Date: 9 Mar 1998 18:53:47 GMT
From: sugalskd@osshe.edu (Dan Sugalski)
Subject: ANNOUNCE: VMS::Persona 1.01
Message-Id: <6e1drr$3rg$1@news1.teleport.com>
Keywords: VMS perl Persona setuid

The VMS::Persona module provides access to the persona services provided
in VMS 6.2 and above. These allow a properly priviliged user to become
another user, complete with that new user's UIC, username, and rights
identifiers.

Version 1.01 of this module, available on CPAN at
$CPAN/authors/Dan_Sugalski/VMS-Persona-1_01.zip, is a minor update to
1.00. It fixes a problem with the module tests and provides better
documentation.




------------------------------

Date: 9 Mar 1998 18:54:04 GMT
From: sugalskd@osshe.edu (Dan Sugalski)
Subject: ANNOUNCE: VMS::Priv 1.31
Message-Id: <6e1dsc$3th$1@news1.teleport.com>
Keywords: VMS perl privilege

			Announcing VMS::Priv 1.31

The VMS::Priv module gives perl scripts the ability to add and drop any
privileges that the user running the script has available. Equivalent to
the DCL SET PROCESS/PRIVILEGE= and SHOW PROCESS/PRIVILEGE commands, this
module also provides access to a user's default privileges as recorded in
the SYSUAF.

Note that this module will *not* violate system security--it can not add a
privilege that a user does not have authorization for.

Available on CPAN, $CPAN/authors/Dan_Sugalski/VMS-Priv-1_31.zip




------------------------------

Date: 9 Mar 1998 18:54:27 GMT
From: sugalskd@osshe.edu (Dan Sugalski)
Subject: Announce: VMS::Process 1.04
Message-Id: <6e1dt3$3vg$1@news1.teleport.com>

Announcing VMS::Process 1.04

This is a minor update to VMS::Process, the module that provides access to
all sorts of information on any process running in your VMS cluster. The
DFWSCNT item was added, and some documentation improvements were made.

Available on CPAN $CPAN/authors/Dan_Sugalski/VMS-Process-1_04.zip




------------------------------

Date: 9 Mar 1998 18:53:04 GMT
From: "Adam C. Graham" <agraham@usa.net>
Subject: ANNOUNCE: Xbase/DBF record manager
Message-Id: <6e1dqg$3qq$1@news1.teleport.com>

http://www.erinbay.com/public_source/dbf.pm
http://www.erinbay.com/public_source/sqldbf.pm

Package to Read/Write DBASE III+ DBF Files.  Uses the 'DB_File' module
for indexes.  There is also a simple SQL SELECT interface (sqldbf.pm).

Bug reports, comments welcome.

ACG


Example Usage:

# Simple SELECT
# =============

# $sql = new sqldbf;
#
# $sqlstr = "SELECT * FROM sales WHERE amt>10 AND amt<100 ORDER_BY amt";

# $str = $sql->command($sqlstr);
#
# $dbf=$sql->{'table_sales'};  # Get the table object for sales
#
# %rec = $sql->get_row;
# while ( keys %rec )
# {
#    print "\nRecord #", $dbf->{'recno'}, "\n";
#    foreach $i(keys %rec)
#    {
#        print "$i: $rec{$i}\n";  # print <field name>: <field value>
#    }
#
#     %rec = $sql->get_row;
# }
# $sql->close;





------------------------------

Date: 09 Mar 1998 12:12:15 -0700
From: Randal Schwartz <merlyn@stonehenge.com>
To: jdporter@min.net
Subject: Re: error???
Message-Id: <8c90qjy8z4.fsf@gadget.cscaper.com>

>>>>> "John" == John Porter <jdporter@min.net> writes:

John> merlin wrote:
>> 


John> Might I gently suggest that you change your pseudonym?
John> The one you have chosen is considered a reserved name
John> in this newsgroup.

Uh, by who?

There are many Randal's, Schwartz's, and merl[iy]n's in the industry.
If you can't distinguish the spelling or the combination of such, it's
gonna make programming much harder as well. :-)

print "Just another Perl hacker," # but not what the media calls "hacker!" :-)
## legal fund: $20,990.69 collected, $186,159.85 spent; just 175 more days
## before I go to *prison* for 90 days; email fund@stonehenge.com for details

-- 
Name: Randal L. Schwartz / Stonehenge Consulting Services (503)777-0095
Keywords: Perl training, UNIX[tm] consulting, video production, skiing, flying
Email: <merlyn@stonehenge.com> Snail: (Call) PGP-Key: (finger merlyn@teleport.com)
Web: <A HREF="http://www.stonehenge.com/merlyn/">My Home Page!</A>
Quote: "I'm telling you, if I could have five lines in my .sig, I would!" -- me


------------------------------

Date: Mon, 09 Mar 1998 13:07:12 -0600
From: Dave Barnett <barnett@houston.Geco-Prakla.slb.com>
Subject: Re: gzipped tar perl manual
Message-Id: <35043DE0.55C35A45@houston.Geco-Prakla.slb.com>

Under win '95 (and others?), a neat program called WinZip version 6.2
handles unix tar/gzip'ped files handily.

A web search for it should provide a download site.

HTH.

Dave

-- 
"Security through obscurity is no security at all."
		-comp.lang.perl.misc newsgroup posting

------------------------------------------------------------------------
* Dave Barnett               U.S.: barnett@houston.Geco-Prakla.slb.com *
* DAPD Software Support Eng  U.K.: barnett@gatwick.Geco-Prakla.slb.com *
------------------------------------------------------------------------


------------------------------

Date: Mon, 09 Mar 1998 19:01:13 GMT
From: address.is@abeaudoi-at-dciem.dnd.ca (A. P. Beaudoin)
Subject: Help, command not being executed, stumped
Message-Id: <35043a80.1274345@news.drenet.dnd.ca>

I'm trying to execute the following command from a perl script:

`var/edu-data/cgi-bin/pstogif -out /var/edu-data/HTML/tmp/x.gif /usr/tmp/s.ps`;

It worked a few weeks ago, and now it does not. I've also tried exec (500 server error)
and system (same non-result as backticks) to no avail. I run this script from the shell
prompt and the command works just fine. But if the script is called through the web, no
dice. I tried capturing any output (there should be either an error message or the results
of a successul execution) but there is none. I've made sure the script reaches that line
by putting debuggers before and after. The directories it reads and writes are in 777
mode, the script itself is in 755 mode, the pstogif program and the s.ps files are both
present and accessible. I can't see why this would fail. Can anyone help?

Please cc your reply to my e-mail address, if you would be so kind. Thanks...


------------------------------

Date: 9 Mar 1998 18:57:07 GMT
From: Fabrizio Pivari <pivari@geocities.com>
Subject: IndexMaker 5.0: an index.html maker from PDF,HTML,VRML and other files
Message-Id: <6e1e23$423$1@news1.teleport.com>

Hi,

I'm glad to announce the version 5.0 of IndexMaker a perl script to make

an index.html file from PDF, HTML, VRML and other files.
At the moment, it uses the /Author field, the first /Title field and
the /Subject field in every matched PDF files, the <TITLE> </TITLE>
field and  the META
Description and Author fields in every matched HTML files the Info node
field in every matched
VRML 1.0 files the WorldInfo node field info and title in every matched
VRML 2.0 files
and the name of the file in the others.

What's new with version 5.0
The code was rewrited in PERL 5.xxx mode
Now I don't support directly PDF. I use the new PDF libray v.1.04 of
Antonio Rosella
http://www.geocities.com/CapeCanaveral/Hangar/4794/

This is the URL where you can find the tool
http://www.geocities.com/CapeCanaveral/Lab/3469

Ciao

--
Fabrizio Pivari
mailto:pivari@geocities.com
http://www.geocities.com/CapeCanaveral/Lab/3469/
Member of ANFACE Software
http://www.geocities.com/CapeCanaveral/Hangar/4794/






------------------------------

Date: 9 Mar 1998 18:58:59 GMT
From: Martin Schwartz <schwartz@cs.tu-berlin.de>
Subject: MS Excel -> HTML
Message-Id: <6e1e5j$43o$1@news1.teleport.com>

Hi there,

I just put release 0.383 of OLE::Storage to CPAN. The most thrilling new
thing should be the utility "herbert", that does simple Excel documents to 
HTML. Apart from at CPAN you will find OLE::Storage at:

	http://wwwwbs.cs.tu-berlin.de/~schwartz/perl/

To use the utilities coming along with the module, you will also have to get 
the modules Startup and Unicode::Map from there or CPAN. The latter can be 
easily substituted with Unicode::Map8, but not yet automatically (will be 
done soon).

Enjoy!

Martin

-- 
// Le degre zero de l'ecriture? Zero probleme!




------------------------------

Date: 9 Mar 1998 18:58:21 GMT
From: Joshua Pritikin <pritikin@mindspring.com>
Subject: ObjStore 1.30
Message-Id: <6e1e4d$43a$1@news1.teleport.com>

=head1 NAME

ObjStore - Perl Extension For C<ObjectStore> OODBMS

=head1 SYNOPSIS

The new C<SQL> and the sunset of relational databases.

=head1 DESCRIPTION

ObjectStore is the market leader in object-oriented databases
http://www.odi.com (NASDAQ: ODIS).  They use a unique Cache-Forward
Architecture to make persistent data available in literally the most
efficient manner possible.

Prior to this joining of forces: ObjectStore was too radical a design
decision for many applications; and perl5 did not have a simple way of
storing complex data persistently.

Now there is an easy way to build database applications, especially if
you are concerned about preserving your ideals of data encapsulation.

=head1 WHAT IS PERSISTENT PERL?

It's just like normal perl, except that you can create data that
doesn't go away when your program exits.  This more permenant data
lives in files or raw disk partitions that are divided into databases.
And databases are comprised of...

=head1 PREREQUISITES

If you want to find out, you need:

- ObjectStore OODBMS (see http://www.odi.com; evaluations are available!)

- Perl 5.004_04 (or perl 5.005, once released)

- Tree::Fat & Test perl extensions

- ExtUtils::ExCxx (only needed on Digital UNIX, HP (5.x), OS/2 (3.x),
  or MS Windows NT/95; send email)

See http://www.perl.com/CPAN/authors/id/JPRIT/ !


##################
# RECENT CHAN@ES #
##################


** 03-06-98 RELEASE 1.30

- Instant, effortless event dispatching for network distributed perl
objects using dynamic transactions.  (See ObjStore::Process :-)

- posh now persists command history from prior sessions (5.004_58+).


** 02-21-98 RELEASE 1.29

- Complete, nesting, tied array support (5.004_58+).

- Rewrote ObjStore::AppInstance to eliminate unnecessarily confusing
data flow.  The new version is NOT backward compatible.




------------------------------

Date: Mon, 09 Mar 1998 13:22:31 -0600
From: Aaron Hanson <aahanson@students.uiuc.edu>
Subject: OUT OF MEMORY???
Message-Id: <35044177.6F7F@students.uiuc.edu>

Hi all.  I have a database file that I use to keep track of basbeball
statistics...  I wrote this PERL program to look through the database
and compile stats, and then print them out to HTML....  Up until
recently, it was working fine.  But now, when I load the page, it prints
a little of the page, and then "Out of Memory".  I suspect that this is
because the size of the database exceeds some sort of limit...  Well,
not the databse itself, but my data structure inside my PERL script that
stores the data...  I used a Hash, with each key being a player name
pointing to a hash of stats (keys=stat names, pointing to stat
values...  Example:  $data{griffey}{atbats} = 514; etc...).  The number
of player keys is about 250, and the number of stats for each player is
about 20.  IS this exceeding some internal memory limit or hash size
limit?  Well, really all I am asking is how can I get this to work for
large amounts of data.  How can I get rid of this error message?  Please
drop me a line if you can...  I really need the help...

Aaron


------------------------------

Date: Mon, 09 Mar 1998 19:25:47 GMT
From: epa@datcon.co.uk (Ed Avis)
Subject: Parsing environment variables
Message-Id: <35044126.534822113@news-direct>

(This question isn't in the FAQ - I hope I'm allowed to ask it)

I'm reading filenames from a config file.  I'd like to allow the user
to specify environment variables as part of these pathnames.

For example, if the env var $FOO=bar, then reading the following word
from the config file

$FOO/readme.txt

would be converted to

bar/readme.txt 

(and ideally I'd like to give an error if $FOO is undefined, though
this is not essential, I could take $FOO as "" if it's undef.)

N. B. I mean environment variables, as in $ENV{'PATH'}, not Perl's
internal variables.

Is there an easy way to do this?

--
Ed Avis


------------------------------

Date: Mon, 09 Mar 1998 13:42:16 -0600
From: mpeppler@mbay.net
Subject: Re: Perl <-> Sybase
Message-Id: <6e1gki$1ea$1@nnrp1.dejanews.com>

In article <34FFF766.775D@etm.ericsson.se>,
  Geert Roovers <etmgero@etm.ericsson.se> wrote:
>
> and was wondering if somenone could show me some working
> perl code, so that I know how it exactly works? I like learning by
> example, and the manual doesn't provide so much examples.

There are quite a few examples in the /eg directory of the sybperl
distribution.

Michael

-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/   Now offering spam-free web-based newsreading


------------------------------

Date: Mon, 09 Mar 1998 18:54:38 +0000
From: Gregory Propf <gregp@home.com>
Subject: Perl Hash question
Message-Id: <35043AEE.DAAA2121@home.com>

I recently wrote a module that takes a hash as an argument - at least I
thought it did... I realized that what was actually being passed in was
a plain 'ol array.  I managed to cruft something together that involved
reading the hash pairs and making up a string version of the command to
declare a hash and then doing "eval $hashcmd" within the module (I'm
trying to create a module-local version of the hash).  It worked but I
can't help but think there's a better way.  I'm fairly new to Perl and
DON'T have the "Camel book" to help me (can't afford it right now).  Any
ideas welcome.  Also any GOOD Perl tutorials on the web are welcome.  I
have the perl man pages that come with Linux but I'm just not getting
what I need from them.

-- 
------------------------------------------------------
| Visit my website at http://members.home.net/gregp/ |
| #include <sig.h>				     |
------------------------------------------------------


------------------------------

Date: 09 Mar 1998 14:08:24 -0500
From: Jonathan Feinberg <jdf@pobox.com>
Subject: Re: Perl Hash question
Message-Id: <90qj7kd3.fsf@news.concentric.net>

Gregory Propf <gregp@home.com> writes:

> I recently wrote a module that takes a hash as an argument - at least I
> thought it did... I realized that what was actually being passed in was
> a plain 'ol array.

> I'm fairly new to Perl and DON'T have the "Camel book" to help me
> (can't afford it right now).

You don't *need* the Camel.  You do need to read (at least) two of the
documents that came with perl.  They are called "perlsub," and
"perlref."  These will explain the use of references and sub
prototypes (any combination of which may be useful to you in this
case).

-- 
Jonathan Feinberg   jdf@pobox.com   Sunny Brooklyn, NY


------------------------------

Date: Mon, 09 Mar 1998 18:53:11 GMT
From: edwin_van_stam@nl.compuware.com (Edwin J. van Stam)
Subject: PERL32 / mail / NT40
Message-Id: <350269c0.3224813@news>

Hello,

I need some source coding with which I can create a mail from a
perlscript. Ok, on unix boxes you have the sentmail option, but that's
not available on NT 4.0.

Is there any way to sent responses by mail, with usage of Perl? I know
the existence of a MAIL:: module, but that's also Unix oriented, I'm
afraid.

In case you have something on this, your response is very welcome.

Edwin_van_Stam@nl.compuware.com


------------------------------

Date: Mon, 09 Mar 1998 13:48:24 -0500
From: Doug Carr <dcarr@ivation.com>
To: Tze Weng Foong <tfoong@patrick.com.au>
Subject: Re: PerlW32 on NT, cannot use > or |  why?
Message-Id: <35043978.604138AA@ivation.com>

I'm not sure why, but I think it has to do with the mechanism used to
associate file extensions with executables (a .pl file is associated with
the perl.exe executable, .html is associated with netscape or internet
explorer, etc.).  Try this:

perl -S hello.pl | more

and it should work.  You don't need the -S if the script is in your
current directory or you specify the path to it.

Doug.

Tze Weng Foong wrote:

> Hello All,
>
> I am not able to get the data redirected to a file or piped to another
> program!

> <snip>
> C:> hello.pl | more
>
> Nothing happens, no output.
>





------------------------------

Date: Mon, 09 Mar 1998 13:11:14 -0600
From: Rich Grise <lovegod@earthling.net>
Subject: Please Disregard this old thing
Message-Id: <35043ED2.5EC@earthling.net>

Rich Grise wrote:
> 
 ....some stuff....
but it was some time ago, and I don't know how to operate
my NS Mail or NS News, so they sat in my outbox until today.
Sorry.




------------------------------

Date: 9 Mar 1998 18:59:35 GMT
From: Sanford Morton <sanford@halcyon.com>
Subject: Plot.pm - Front end to GD.pm for plotting two dimensional data
Message-Id: <6e1e6n$443$1@news1.teleport.com>

The module, manual, and a cgi demonstration script are available at

    http://www.speakeasy.org/~cgires/plot/

I'd like to receive comments before releasing to CPAN.

I wrote Plot.pm to create some simple graphs in gif format of two
dimensional scientific data. The other graphing interface modules to
GD.pm I saw on CPAN either could not handle negative data, or could
only chart evenly spaced horizontal data.

Plot.pm will plot multiple data sets in the same graph, each with
some negative or positive values in the independent or dependent
variables. Each dataset can be a scatter graph (data are represented
by graph points only) or with lines connecting successive data points,
or both. Axes are scaled and positioned automatically and 5-10 ticks
are drawn and labeled on each axis.

Plot.pm requires the GD.pm library by Lincoln Stein, available at
http://www.genome.wi.mit.edu/ftp/pub/software/WWW/GD.html or on CPAN.

This is a first draft, so it may not always work right, and the public
interface may change.




------------------------------

Date: Mon, 09 Mar 1998 14:47:03 -0500
From: John Porter <jdporter@min.net>
Subject: Re: Problem with "goto" in Perl
Message-Id: <35044737.3AAA@min.net>

Uri Guttman wrote:
> 
> aml@world.std.com (Andrew M. Langmead) writes:
> >
> > Another example in perl is eval. The function "eval STRING" should be
> > avoided, but "eval BLOCK" is important and useful.
> 
> i disagree. eval STRING is VERY useful to generate closures, fast
> multi-regex subs, and other dynamic code objects. eval BLOCK is mostly
> used for run time error handling. they are very different animals which
> share the same name (unfortunately)

That's right, they are different animals.  eval STRING, while useful
in certain very special cases, is generally best avoided, when other
mechanisms, such as eval BLOCK, symbolic references, and real closures,
are also viable.

John Porter


------------------------------

Date: 9 Mar 1998 19:28:11 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: random numbers?
Message-Id: <6e1fsb$sb4$1@client2.news.psi.net>

mwsasser!nospam!@timetrend.com (mwsasser!nospam!@timetrend.com) wrote on
1651 September 1993 in <URL: news:3504323b.74917305@news.ax.centuryinter.net>:
++ 	I'm trying to generate real random numbers but all I generally
++ get are numbers from 8 to 14 when I try adding 3 random numbers from 1
++ to 6.  Should not 9 be the average number here?  I'm trying
++ int(rand(6)+1)   what am I missing?

Did you try enough samples?

$ perl -w
use strict;
my @bucket;
@bucket [3 .. 18] = (0) x 16;
foreach (1 .. 100_000) {
   $bucket [int (rand (6) + 1) + int (rand (6) + 1) + int (rand (6) + 1)] ++;
}
foreach (3 .. 18) {
   printf "%2d: %5d\n", $_, $bucket [$_];
}
my $s = 0;
map {$s += $_ * $bucket [$_]} (3 .. 18);
printf "Average: %f\n", $s / 100_000;
__END__
 3:   482
 4:  1398
 5:  2658
 6:  4730
 7:  6913
 8:  9752
 9: 11685
10: 12548
11: 12434
12: 11554
13:  9824
14:  6824
15:  4641
16:  2695
17:  1372
18:   490
Average: 10.493090
$

Considering the theoretical average is 10.5, 10.49 isn't bad.



Abigail
-- 
perl -we 'print split /(?=(.*))/s => "Just another Perl Hacker\n";'


------------------------------

Date: 9 Mar 1998 19:10:42 GMT
From: baboulen@aol.com (Baboulen)
Subject: Relational arrays
Message-Id: <19980309191001.OAA22333@ladder02.news.aol.com>

Hi,

I'm trying to 'connect' two lists.

LIST1


DISK	PHYSICAL  SIZE  ....

disk1	c0t0d0	  4Go	....
disk2	c1t0d0	  2Go	....
disk3	c2t0d0	  2Go	....
disk4	c3t0d0	  4Go	....
 .....	......	  ...	....



LIST2

VOL	DISK	.....

name1	disk3	.....
name2	disk2	.....
name3	disk3	.....
 .....	.....	.....



I want to print a line like :

	VOL	DISK	PHYSICAL   .....

	name1	disk3	c2t0d0	   .....
	name2	disk2	c1t0d0	   .....
	name3	disk3	c2t0d0	   .....

I want to join LIST1 and LIST2 on DISK name.

How should i do ?

Thanks

Eric BABOULENE


------------------------------

Date: 9 Mar 1998 19:01:17 GMT
From: swmcd@world.std.com (Steven W McDougall)
Subject: Set::IntSpan 1.06 released - bug fix
Message-Id: <6e1e9t$49l$1@news1.teleport.com>

Set::Intspan 1.06 has been uploaded to PAUSE and is propagating
through the CPAN. In version 1.05, the expression

   Set::IntSpan->new->union("0")

returned the empty set. In version 1.06, it returns the set {0}.



>From the README file:


   Set::IntSpan VERSION 1.06 - Manages sets of integers

   DESCRIPTION
   Set::IntSpan manages sets of integers.  It is optimized for sets that
   have long runs of consecutive integers.  These arise, for example, in
   .newsrc files, which maintain lists of articles:

       alt.foo: 1-21,28,31
       alt.bar: 1-14192,14194,14196-14221

   Sets are stored internally in a run-length coded form.  This provides
   for both compact storage and efficient computation.  In particular,
   set operations can be performed directly on the encoded
   representation.



>From the Changes file:

   Revision history for Perl extension Set::IntSpan

   1.06  Mar  3 1998
	   - fixed real_set "0" bug



- SWM





------------------------------

Date: Mon, 09 Mar 1998 14:16:45 -0500
From: John Porter <jdporter@min.net>
Subject: use Module vs. no Module ???
Message-Id: <3504401D.3B8A@min.net>

I know that use Module LIST causes a require of Module,
and calls Module::import( LIST );
my question is, if I say "no Module", does it result in a
call to a sub in Module?  If so, what's it called?

Thanks,

John Porter


------------------------------

Date: 9 Mar 1998 19:42:09 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: Using perl to do what a spreadsheet does but with a plain text file as a source?
Message-Id: <6e1gmh$132$1@client3.news.psi.net>

Tony Gonzalez (oak@crl.OmitThis.com) wrote on 1650 September 1993 in
<URL: news:6dtvsi$kmu$1@nnrp1.crl.com>:
++ I'd like to use perl to do what a spreadsheet does but with a plain
++ text file as a source, for example, if I have a text file like this:
++ 
++ 
++                    Mon.    Tues.    Total
++                    ------------------------
++ Joe Schmoe          5.3     1.2     TOTAL?
++ John Doe            2.5     4.6     TOTAL?
++ William Henry       1.3     3.2     TOTAL?
++ 
++ Is there any way I can generate a report like the above with the
++ totals computed?


If that's really the format of your input file, try:

perl -pe 's{TOTAL\?}{do {my $s = 0; map {$s += $_} m{(\d+(?:\.\d+)?)}g; $s}}e' 

followed by the file(s) with the above format.



Abigail
-- 
perl -MLWP::UserAgent -MHTML::TreeBuilder -MHTML::FormatText -wle 'print +(HTML::FormatText -> new -> format (HTML::TreeBuilder -> new -> parse (LWP::UserAgent -> new -> request (HTTP::Request -> new ("GET", "http://work.ucsd.edu:5141/cgi-bin/http_webster?isindex=perl")) -> content)) =~ /(.*\))[-\s]+Additional/s) [0]'


------------------------------

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V8 Issue 2058
**************************************

home help back first fref pref prev next nref lref last post