Jeffrey Cohen
and 1 contributors

NAME

Genezzo::Row::RSFile - Row Source File tied hash class.

SYNOPSIS

 use Genezzo::Row::RSFile;

DESCRIPTION

RSFile is a hierarchical pushhash (see Genezzo::PushHash::hph) class that stores scalar data in a block (byte buffer) via Genezzo::Block::RDBlock.

ARGUMENTS

tablename (Required) - the name of the table
tso (Required) - tablespace object from Genezzo::Tablespace
bufcache (Required) - buffer cache object from Genezzo::BufCa::BCFile

CONCEPTS

RSFile can persistently store scalar data in a single file. It doesn't know anything about rows -- that's all in Genezzo::Row::RSTab.

RSFile has some extensions to directly manipulate the underlying blocks. These extensions are useful for building specialized index mechanisms (see Genezzo::Index) like B-trees, or for supporting scalars that span multiple blocks.

Basic PushHash

You can use RSFile as a persistent hash of scalars if you like. RSFile can only support strings that fit with a single database block. Use Genezzo::Row::RSTab if you need to split data over multiple blocks.

HPHRowBlk - Row and Block operations

HPHRowBlk is a special pushhash subclass with certain direct block manipulation methods. One very useful function is HSuck, which provides support for rows that span multiple blocks. While the standard HPush fails if a row exceeds the space in a single block, the HSuck api lets the underlying blocks consume the rows in pieces -- each block "sucks up" as much of the row as it can. However, RSFile does not provide the HSuck api. Instead, it provides some utility functions so RSTab can get direct access to the low-level block routines.

Counting, Estimation, Approximation

RSFile has some support for count estimation, inspired by some of Peter Haas' work (Sequential Sampling Procedures for Query Size Estimation, ACM SIGMOD 1992, Online Aggregation (with J. Hellerstein and H. Wang), ACM SIGMOD 1997 Ripple Joins for Online Aggregation (with J. Hellerstein) ACM SIGMOD 1999).

FUNCTIONS

RSFile support all standard hph hierarchical pushhash operations.

EXPORT

LIMITATIONS

various

TODO

need error handlers vs "whisper"

AUTHOR

Jeffrey I. Cohen, jcohen@genezzo.com

SEE ALSO

perl(1).

Copyright (c) 2003-2007 Jeffrey I Cohen. All rights reserved.

    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

Address bug reports and comments to: jcohen@genezzo.com

For more information, please visit the Genezzo homepage at http://www.genezzo.com