GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  DBIX::SQLENGINE::DRIVER::TRAIT::NOCOMPLEXJOINS (3)

.ds Aq ’

NAME

DBIx::SQLEngine::Driver::Trait::NoComplexJoins - For databases without complex joins

CONTENTS

SYNOPSIS



  # Classes can import this behavior if they dont have joins using "on"
  use DBIx::SQLEngine::Driver::Trait::NoComplexJoins :all;
 
  # Implements a workaround for missing "inner join on ..." capability
  $rows = $sqldb->fetch_select_rows( tables => [
    foo, inner_join=>[ foo.id = bar.id ], bar
  ] );
 
  # Attempts to use an "outer join" produce an exception
  $rows = $sqldb->fetch_select_rows( tables => [
    foo, outer_join=>[ foo.id = bar.id ], bar
  ] );



DESCRIPTION

This package supports SQL database servers which do natively provide a SQL select with inner and outer joins.

This package causes inner joins to be replaced with cross joins and a where clause. Outer joins, including left and right joins, are not supported and will cause an exception.

    About Driver Traits

You do not need to use this package directly; it is used internally by those driver subclasses which need it.

For more information about Driver Traits, see About Driver Traits in DBIx::SQLEngine::Driver.

REFERENCE

    Database Capability Information

dbms_join_on_unsupported


  $sqldb->dbms_join_on_unsupported() : 1



Capability Limitation: This driver does not support the join ... on ... syntax.

dbms_outer_join_unsupported


  $sqldb->dbms_outer_join_unsupported() : 1



Capability Limitation: This driver does not support any type of outer joins.

    Select to Retrieve Data

sql_join()


  $sqldb->sql_join( $table1, $table2, ... ) : $sql, @params
  $sqldb->sql_join( $table1, \%criteria, $table2 ) : $sql, @params
  $sqldb->sql_join( $table1, $join_type=>\%criteria, $table2 ) : $sql, @params



Processes one or more table names to create the from clause of a select statement. Table names may appear in succession for normal cross joins, or you may specify a join criteria between them.

Inner joins are replaced with normal comma cross joins and a where clause. Use of a left, right or full outer join causes an exception to be thrown.

Note that using join criteria will cause the return from this method to be a bit different than that of the superclass; instead of just being a from expression with table names, the returned SQL statement will also include a where expression. Conveniently, the sql_where method allows post-processing of a statement that already includes a where clause, so this value can still be combined with additional criteria supplied as a separate where argument to one of the select methods.

SEE ALSO

See DBIx::SQLEngine for the overall interface and developer documentation.

See DBIx::SQLEngine::Docs::ReadMe for general information about this distribution, including installation and license information.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 SQLENGINE::DRIVER::TRAIT::NOCOMPLEXJOINS (3) 2004-11-07

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.