Class-DBI

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

    perl version (Juan Camacho) and allow for closures (RT#15498)
  - Remove lots of old deprecations

3.0.11 Oct 23 2005

  - search through a has_many can now take hash_ref
  - Fix documentation for SQL wildcards (RT#15145)

3.0.10 Oct 7 2005

  - Set Storable::Deparse so that has_a subrefs can be cloned (Will Ross)
  - Use shorter version of mk_classdata
  - Include t/24 which was accidentally left out of MANIFEST in 3.0.9

3.0.9 Sep 23 2005

  - Fixed bug with shared meta_info (Will Ross)

  - create() has been renamed to insert() to make it much clearer that
    it corresponds to an SQL INSERT rather than lots of different ideas
    as to what create() might mean. create() still (silently) works. It
    will give 'deprecated' warnings from 3.2.0 and will be removed no
    earlier than 3.4.0.

    The before/after create triggers have NOT been renamed yet as I'm
    rethinking some of that. We'll probably end up with more trigger
    points. Comments and suggestions welcome.

3.0.8 Sep 20 2005

  - constraint exceptions now set their 'data' (Dan Collis Puro)
  - method created by has_many can now override method in parent class
     (reported by Christopher H. Laco)
  - factored out transform_sql for easier modification

3.0.7 Sep 17 2005

  - Make Column responsible for accessor() and mutator() so they can be
    set up declaratively as well as programmatically (this means the
    second argument to accessor_name and mutator_name is now a Column
    object rather than its name, so you may need to check your case
    sensitivity)
  - Rename accessor/mutator_name to accessor/mutator_name_for
  - Document that order_by clauses in sort() are passed through
  - Make one-shot 'Essential' set up slightly more explicit in docs
    (Adam Kennedy)
  - Fix HasMany warning typo (argumemt) (Dan Friedman)
  - Remove obsolete SearchGenerator code which had leaked out

3.0.6 Sep 16 2005

  - constrain_column can now take subref constraint
  - Document DBD::AnyData and FreeTDS issues (Matt Trout)
  - Factor out database error handling to _db_error()
  - Switch to Class::Accessor::Fast in Column and Relationship 

3.0.5 Sep 14 2005

  - has_many can take compile time constraints (Cees Hek)
  - has_many can take a cascading delete strategy (deprecating the old,
    undocumented, 'no_cascade_delete' option)
  - columns() can take Class::DBI::Column objects directly
    which can now in turn take options, thus allowing things like:
      __PACKAGE__->columns(dates => Class::DBI::Column->new(
        tdate => { placeholder => 'IF(1, CURDATE(), ?)' }
      )

3.0.4 Sep 13 2005

  Pre-Reqs
    - Note requirement for Scalar::Util 1.08+ (for refaddr)

  Refactorings
    - Move to pluggable Search interface 
       (includes reworking of search approach per Tim Bunce)

3.0.3 Sep 11 2005

  Bug Fixes
    - Ensure object is removed from index when delete()d (Tim Bunce)
    - clear_object_index when new relationship set up (Tim Bunce)
    - Fixed bug where PK values got auto-vivified 
       (Tatsuhiko Miyagawa, Christopher L. Everett, Tim Bunce)
    - Removed 'AS' when aliasing tables; some databases don't like that
    - Properly return -1 from unchanged object updates (Kingsley Kerce)
    - Fixed problems with overloaded stringification of related classes
       (Tim Bunce)
    - Fixed bug where Essential might contain the PK twice 

  Refactorings
    - Split live_object_key for easy subclassing (Tim Bunce)
    - Split out _as_hash() to return underlying data hash
    - Optimised _mk_column_accessors (Maurice Aubrey)
    - Don't hard-code relationship names (Peter Speltz)

  Internals
    - Changed error message when setting up has_a with incorrect column
       (Drew Taylor)

  Documentation
    - Fixed docs for after_update trigger and update (Kingsley Kerce)

3.0.2 Sep 11 2005

  Code
    - No changes

  Pre-Reqs
    - Fixed code to explicitly need 5.6 (rather than just Makefile)
    - Require 'version' for new 3 part versions

  Tests
    - Fixed t/01 to check mutator_name better
    - Added NOT NULL to Primary in t/Blurb to avoid 0.95 regression
    - Added new Test base class Class::DBI::Test::SQLite
    - Changed all remaining uses of eq_set() to is_deeply()

  Documentation
    - Documented $obj->id() in list context (William McKee)
    - Documented cascading delete for might_have (Tom Hukins)
    - Documented MCFK better (plus fixed lots of typos etc) (Tom Hukins)

Changes  view on Meta::CPAN

    - sort argument to has_many is now order_by to match search
    - __hasa_rels and __hasa_list are deprecated in favour of meta_info

  Other
    - construct() is no longer a protected method. 
    - skip t/17 on error. There's a bug here I can't find, or fix, yet.

0.95 Fri Jan  9 2004

  Pre-Requisites
    - Now requires Perl 5.6 or greater

  New Functionality
    - constrain_column() adds simple per-column constraints
    - has_many now attempts to work out the reference column by
      examining the foreign class's has_a() declarations, making the 3rd
      argument to has_many mostly obsolete.
    - __TABLE(Other::Class)__ now interpolates the table from the other
      class, allowing avoidance of hard-coding other table names.
    - __ESSENTIAL(alias)__ now prepends the table alias supplied to the
      start of each column name, for avoiding column name clashes.
    - __JOIN(alias alias)__ now inserts the SQL to join the two tables.
    - might_have now allows creating the remote object through a simple
      set of the accessor. [David Jack Olrik]
    - Iterators can now be reset() [Tatsuhiko Miyagawa]

  Documentation
    - count_all, maximum_value_of and minimum_value_of are now
      documented (along with how to implement similar methods)

  Bug Fixes
    - Allow retrieve() to take unnormalised columns, as with search [Connie]
    - Handle stringification before Primary Key(s) are filled 
    - search() can take an overridden accessor name as a key
    - MultiColumn primary keys working better with ColumnGrouper [Perrin
      Harkins, Paul Makepeace, and Charles Bailey]

  Deprecations
    - _single_value_select and _single_row_select deprecated in favour
      of new select_val and select_row methods in Ima::DBI

  Other
    - Class::Accessor can no longer be used directly to add other attributes.
      TEMP columns should be used for this.
    - Ensure all croaks internally go through _croak() [Richard Piacentini]
    - deleted objects now blessed into Class::DBI::Object::Has::Been::Deleted
    - Lots of doc patches [Jesse Sheidlower, Paul Makepeace]
    - All internal attribute accesses now go through helper methods,
      as first step to changing how all this works.
    - set_sql now passes all arguments up to Ima::DBI (so you can turn
      off caching if required) [gfalck]
    - We now warn about column names clashing with any inherited methods,
      not just ones defined in Class::DBI itself [Dan Thill]
    - Silence some test warnings reported by Paul Makepeace

0.94  Wed Aug 27 2003

  New Functionality
    - allow has_a() columns to hold NULL values (Dominic Mitchell)
    - cascading deletions can be turned off by passing argument to
      has_many setup: no_cascade_delete => 1 (undocumented/untested)
      [now implemented as a trigger]
    - classes and objects can be marked as read_only (experimental and
      undocumented, although tested)

  Documentation
    - no longer refer to Class::DBI::Join, which is dead
    - warn about inflating a primary key using has_a
    - rewrite of docs on transactions
    - numerous small tweaks from Jay Strauss, Alexander Karelas and Brad
      Bowman
    - redocument dbi_commit and dbi_rollback that have vanished...

  Bug Fixes
    - make sequences work again (Dominic Mitchell) [now with tests!]
    - interpolation of __TABLE__ etc now happens globally, rather than
      only once [Corion]
    - might_have now properly does a cascading delete
    - Fixed problem where we can't update an object which might_have a
      relationship, but doesn't.
    - might_have's tentative, but broken, support for MCPK has been
      removed.
    - Increase Class::Accessor pre-requisite to 0.18 to fix strange bug
      reported by Casey West.
    - Make sure we don't alter the hashref being passed to create()
    - The after_create() trigger is now called after the object is
      emptied, and will thus be able to see objects in has_a columns
      (by reloading from the DB) [If you were using this
      trigger to alter the columns to be cleaned out this
      can (for now) be done using the 'create' trigger,
      although that's deprecated. Let me know if you really
      need this ability.

  Deprecations
    - move() is deprecated. The concept is broken and will be removed
      unless someone convinces me to keep it.
    - normalize* are no longer necessary, due to the new Column objects,
      which store their normalized and unnormalize form. (Calling these
      will have no effect, other than a warning).
    - has_column deprecated in favour of find_column

  Other
    - init() now takes hash to instantiate with (Tim Bunce)
    - Rewrite of _require_class, with better short-circuiting and error
      message reporting (Tim Bunce)
    - new Class::DBI::Column to represent a column. Some functionality
      moved from ColumnGrouper to here.
    - mutator and accessor name overrides now stored in column, and not
      looked up every time.
    - attempt to trap and propogate all DBI failures 

0.93  Wed Jul 2 2003

  New Functionality
    - Multi-column primary keys are now supported. [with huge thanks to Tim
      Bunce]
    - New syntax for inbuilt SQL
    - classes can control stringification via as_string() and
      stringify_column().
    - set_sql automatically translates __TABLE__, __ESSENTIAL__, and
      __IDENTIFIER__

Changes  view on Meta::CPAN

    - normalize_one() deprecated in favour of _normalize_one
    - If a 'might-have' link points to nothing, don't give a 'Can't call
      method' error
    - better reporting on errors from create etc.
    - better reporting when you incorrectly set through hasa()
    - handle primary/foreign key value of zero better
      (reported by Jim O'Brien)
    - added (undocumented) 'column_type' based on ideas from
      Matthew Simon Cavalletto and Tatsuhiko Miyagawa.
    - brought delete triggers in line with documentation
      (reported by Barry Hoggard, fixed by Tatsuhiko Miyagawa)

0.88 Beltane 2000
    - fix for hasa() and create() with modified accessor/mutator names
      (Thanks to Schwern)

0.87 Fri Mar 29 2002
    * added might_have method
    - better MySQL autoincrement code (fixes occassional problems
       under mod_perl) [Thanks to Tatsuhiko Miyagawa]
    - fixed a test that was failing on 5.005 (but not 5.6.1) due to weird 
      interaction between overloaded iterator and Test::More's ok() 
      prototype  [Thanks to Tatsuhiko Miyagawa]

0.86 Fri Mar  8 GMT 2002
    * removed support for pseudo-hashes
    * hasa_list is now has_many 
      (although has_many still exists for backwards compatability)
    + has_many auto-generates reciprocal hasa decalaration
       (unless called as hasa_list, or with { nohasa => 1 })
    * searches now return iterators when used in scalar context
    - hooks are now called 'triggers' (using Class::Trigger)
    * new trigger for SELECT
    * added basic constraints
    + added support for filters on the same column
      (%s >= ? OR %s <= ?) 
    + added 'between' filter which provides this
    - deal better with the case where the only column group is 'All'
    - much internal twiddly stuff

0.36  Wed Nov 28 2001
    + tests no loner die horribly if you don't have MySQL installed
    - minor tweaks to some error messages
    - bugfixes for problems with auto-deleting objects
    - bugfix for mis-normalized accessor warning
       (thanks to Schwern)

0.35  Sun Oct  7 2001
    + added hooks for create, update and delete
    - split commit() for easier subclassing

0.34  Sat Oct  6 2001
    - Don't die if a value is a reference. (Ima::DBI does this for us,
       and better in case of overloaded objects)
    - fix minor problem with mutual hasa / hasa_list referencing
    - better diagnostics if hasa_list is miscalled

0.33  Sat Sep 15 2001
    + Added create_filter(), and with it retrieve_all()
    + added docs on how to set-up many-to-many relationships
    + _cascade delete now split out to allow overriding
    + copy() and move() can now take multiple arguments to change
       (thanks to Jonathan Swartz)

0.32  Sun Sep  9 2001
    + delete() now removes any foreign elements, to avoid orphans

0.31  Sun Sep  9 2001
    + split out _column_placeholder (thanks to Jonathan Swartz)
    + added hasa() checks for orphaned rows

0.29  Wed Sep  5 10:24:54 BST 2001
    + split docs into Class::DBI::Tutorial
    + renamed is_column to has_column (is_column still provided as alias)
    + added accessor_name and mutator_name form template methods
    - _load_class didn't work. Now fixed.
    - _next_in_sequence was broken, and would warn even if it wasn't.
    - better diagnostics when you call retrieve incorrectly

0.28  Wed Aug 29 20:02:28 BST 2001
    + Tony Bowden took over maintenance
    * Added hasa_list
    - Fixed bug with inherited columns (reported by Boris Mouzykantskii)
    - move() and copy() were broken with auto_increments. Now fixed.
    - set() did bad things if you'd set up new fields with
      mk_accessors (reported by Boris Mouzykantskii). Now fixed.
    - Better errors when calling create() incorrectly
    - Split tests into distinct files (DBD::CSV now required)
    - General internal tidying

0.27  Mon Apr 23 09:04:51 BST 2001
    * Class::DBI->new() deprecated in favor of create()
    - Fixed the 'Primary before All' bug reported by Tony Bowden

0.26  Mon Apr  9 14:32:17 BST 2001
    - Class->columns('All', @cols) now assumes the first column to be
      your primary.
    - Class->columns('Essential', @cols) now automatically includes
      the primary column.
    * move() was broken.  Works and tested.
    - Updated our base requirement to get at its bugfix
    - Updated our Ima::DBI requirement to get at commit() and rollback()
    * Documented construct()
    * Added docs about transactions
    * Added dbi_commit() and dbi_rollback()
    - Added docs about Class::DBI and mod_perl

0.25  Wed Jan 10 01:54:27 EST 2001
    - The new ID is now optional for copy()
    * Added move() to move objects between classes/databases.
    - Updated PG's default attributes.
    - Made the way classes are loaded with hasa() safer

0.24  Thu Oct  5 19:07:21 EDT 2000      *UNRELEASED*
    - Fixed some $@ naughtiness.  Errors should propigate properly.
    * Added default database attributes for Pg, MySQL, Oracle, DBD::CSV and
      DBD::RAM.  Class::DBI should work out of the box with them now.

0.23  Tue Sep 12 00:33:38 EDT 2000
    - rollback() needed to normalize its data (thanks to Greg Bartlett)



( run in 1.008 second using v1.01-cache-2.11-cpan-39bf76dae61 )