The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

DBIx::SQLEngine::Mixin::NoComplexJoins - For databases without complex joins

SYNOPSIS

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

DESCRIPTION

This mixin supports SQL database servers which do natively provide a SQL select with inner and outer joins. Instead, inner joins are replaced with cross joins and a where clause. Outer joins, including left and right joins, are not supported and will cause an exception.

Note: this feature has been added recently, and the interface is subject to change.

Caution

Because of the way DBIx::AnyDBD munges the inheritance tree, DBIx::SQLEngine subclasses can not reliably inherit from this package. To work around this, we export all of the methods into their namespace using Exporter and @EXPORT.

Note that, strictly speaking, this is not a real mixin class, but the above implementation issue was not discovered and worked around until after the package namespace had already been put into service.

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.