-
-
24 May 2021 11:36:26 UTC
- Distribution: FunctionalPerl
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Repository
- Issues (0)
- Testers (100 / 2 / 13)
- Kwalitee
Bus factor: 1- License: perl_5
- Perl: v5.16.4
- Activity
24 month- Tools
- Download (443.46KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
and 1 contributors-
Christian Jaeger
- Dependencies
- Digest
- File::Path
- Getopt::Long
- Import::Into
- Math::BigInt
- NEXT
- PerlIO::utf8_strict
- Safe::Isa
- Scalar::Util
- Symbol
- Test::More
- autobox
- base
- overload
- utf8
- warnings
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
FP::DBI - DBI with results as lazy lists
SYNOPSIS
use FP::DBI; $dbh = FP::DBI->connect($data_source, $username, $auth, \%attr); # same as `DBI`: .. $sth = $dbh->prepare($statement); .. $rv = $sth->execute; # then: my $s = $sth->row_stream; # purearrays blessed to FP::DBI::Row # or #my $s = $sth->array_stream; # arrays # or #my $s = $sth->hash_stream; # hashes use PXML::XHTML; TABLE (TH($s->first->map (\&TD)), $s->rest->take (10)->map (sub {TR($_[0]->map (\&TD))}))
DESCRIPTION
Get rows as items in a lazy linked list (functional stream).
NOTE: `DBI` is designed so that when running another `execute` on the same statement handle, fetching returns rows for the new execute; this means, a new execute makes it impossible to retrieve further results from the previous one. Thus if a result stream isn't fully used before a new `execute` or a different result request is being made, then the original stream can't be further evaluated anymore; to prevent this from happening, an interlock mechanism is built in that throws an error in this case.
SEE ALSO
NOTE
This is alpha software! Read the status section in the package README or on the website.
Module Install Instructions
To install FunctionalPerl, copy and paste the appropriate command in to your terminal.
cpanm FunctionalPerl
perl -MCPAN -e shell install FunctionalPerl
For more information on module installation, please visit the detailed CPAN module installation guide.