Hi all,

I am searching for a good ORM. I found some ORMs but somehow none of them seems to have what I am looking for.

I need something like Multi-Table-Objects.

Well I found some ORMs supporting them, but not in perl. For example there are SQL Alchemy for python and hibernate for java.

I need are objects consisting out of more than just one table. Joined together as needed but transparent for the application.

e.g.:
User consisting out of following tables:
user user_contact user_settings user_profile

As needed the contact-info, the settings and the profile are joined together into the user-object.

Yes the example is clumsy and no one will see a need in having them all in one object. But think about historically grown data structures. Changing them is nearly impossible without having an abstraction layer between the application code and the data-structures.

This can not be managed with one-to-one relations, like they are available in nearly every ORM. Being able to handle this with one object rather than a relation is a great thing, enables one to push fields around the database, split tables and do whatever needs to be done to the Database without changing more than just one class.

If they would be in different classes moving a field to another table would require to change two classes and every code-line accessing the attribute in any way.

See I want to have some more abstraction from the Database within the application.

I do not only want to stop loading specific fields, I want to keep tables slim, small and fast.

I want to be able to change database-layout (up to a certain extent) without having to change tons of lines of sql code widely spread among hundreds of modules and scripts.

What I specially need in an ORM:

I see no problems with most of them, but with the first one...

Does anyone know a ORM fitting my needs in perl?

Regards Alex

In reply to Search for ORM with Multi-Table-Object Support by Xel

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.