Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
SQLEngine::Record::ExtUser3Contributed Perl DocumeSQLEngine::Record::Extras(3)

NAME
       DBIx::SQLEngine::Record::Extras - Provide extra methods

SYNOPSIS
	 package My::Record;
	 use DBIx::SQLEngine::Record::Class '-isasubclass', 'Extras';

	 my $sqldb = DBIx::SQLEngine->new( ... );
	 My::Record->table( $sqldb->table( 'foo' ) );

DESCRIPTION
       This package provides a multiply-composable collection of functionality
       for Record classes.

       Don't use this module directly; instead,	pass its name as a trait when
       you create a new	record class. This package provides a multiply-
       composable collection of	functionality for Record classes. It is
       combined	with the base class and	other traits by
       DBIx::SQLEngine::Record::Class.

REFERENCE
   Selecting Records
       fetch_records
	     $recordset	= My::Students->fetch_records( criteria	=> {status=>'active'} );

	   Fetch all matching records and return them in a RecordSet.

       fetch_one
	     $dave = My::Students->fetch_one( criteria => { name => 'Dave' } );

	   Fetch a single matching record.

       fetch_id
	     $prisoner = My::Students->fetch_id( 6 );

	   Fetch a single record based on its primary key.

       visit_records
	     @results =	My::Students->visit_records( \&mysub, criteria=> ... );

	   Calls the provided subroutine on each matching record as it is
	   retrieved. Returns the accumulated results of each subroutine call
	   (in list context).

       refetch_record
	     $record->refetch_record();

	   Re-retrieve the values for this record from the database based on
	   its primary key.

perl v5.24.1			  2004-11-16	  SQLEngine::Record::Extras(3)

NAME | SYNOPSIS | DESCRIPTION | REFERENCE

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=DBIx::SQLEngine::Record::Extras&sektion=3&manpath=FreeBSD+12.0-RELEASE+and+Ports>

home | help