> There's some experimental support for stuff like that, but it
> will require you to define a new column class:
>
>
http://www.mail-archive.com/rose-db-object@lists.sourceforge.net/msg00710.ht
ml

Thanks for the suggestion.  I can see it's a clever workaround.  I'm having
a try but am really pushing the limits of my knowledge. In particular, I am
not familiar with OO conventions so please can you advise?:

1.  I have to create a custom column class.
  package GARD::Column::SourceYear;
  use base 'Rose::DB::Object::Metadata::Column::Integer';
  sub select_sql {...}
  etc.

I assume this is just a file.  And I have to create a subdir Column under
the GARD directory where the other GARD modules are found and put the file
in there. Is that right?  And presumably this won't be picked up
automatically so I then have to "use" it somewhere.

2.  I have to register the column type.
Rose::DB::Object::Metadata->column_type_class(...).   Can I do this
any-old-where? Or should the statement perhaps go into the appropriate table
class (Book.pm in my case)?



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to