On Thu, Feb 21, 2008 at 7:11 AM, John Ingram <[EMAIL PROTECTED]> wrote:
> The situation that I'm facing right now is when I set the value of a
> column to one longer than the column length, either through
> instantiation or the column's generated method:
>
> my $user = Foo::User->new( username => 'too_long_username');
>
> or...
>
> $user->username('too_long_username');
>
> Either one of those results in a croak(). Seems to me that
> handle_error() is not inappropriate for that situation.
Just set the "overflow" property of the column to "warn" or "truncate"
to override teh default "fatal" mode:
http://search.cpan.org/dist/Rose-DB-Object/lib/Rose/DB/Object/MakeMethods/Generic.pm#overflow
-John
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Rose-db-object mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rose-db-object