Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: DBIC circular relationship

by NetWallah (Canon)
on Apr 14, 2013 at 21:21 UTC ( [id://1028652]=note: print w/replies, xml ) Need Help??


in reply to Re^2: DBIC circular relationship
in thread DBIC circular relationship

I don't have sufficient experience in DBIC to come up with this, but the documentation looks promising:

From : "See the distinction between create and new in DBIx::Class::ResultSet for details."

To create related objects, pass a hashref of related-object column values keyed on the relationship name. If the relationship is of type multi ("has_many" in DBIx::Class::Relationship) - pass an arrayref of hashrefs. The process will correctly identify columns holding foreign keys, and will transparently populate them from the keys of the corresponding relation. This can be applied recursively, and will work correctly for a structure with an arbitrary depth and width, as long as the relationships actually exists and the correct column data has been supplied.
I'm not sure exactly what it means, but it seems to be a way to update related fkeys.

If you do figure this out, please post a synopsis here.

             "I'm fairly sure if they took porn off the Internet, there'd only be one website left, and it'd be called 'Bring Back the Porn!'"
        -- Dr. Cox, Scrubs

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1028652]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2024-04-26 03:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found