Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Class::DBI has_many

by PodMaster (Abbot)
on Dec 29, 2003 at 13:33 UTC ( [id://317425]=note: print w/replies, xml ) Need Help??


in reply to Class::DBI has_many

See "Mapping" in "has_many" in the Class::DBI docs.
update: also, i'm sure you know Class::DBI provides columns method...

MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
** The third rule of perl club is a statement of fact: pod is sexy.

Replies are listed 'Best First'.
Re: Re: Class::DBI has_many
by arc_of_descent (Hermit) on Dec 29, 2003 at 13:48 UTC

    HI,

    I read the mapping docs, and I just can't get it to work. An example pertaining to the above scenarion would be really helpful!
    Thanks
    --
    arc_of_descent

      I read the mapping docs, and I just can't get it to work. An example pertaining to the above scenarion would be really helpful!
      What did you try? I'm lazy, and I don't like to type.

      MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
      I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
      ** The third rule of perl club is a statement of fact: pod is sexy.


        Fine. I understand.
        Anyways.. this is what I tried

        Page.pm
        __PACKAGE__->has_many(columns => [ 'Page_column' => 'column_id' ]);


        Page_column.pm
        __PACKAGE__->has_many(columns => 'Column');


        Column.pm
        __PACKAGE->has_a(column_id => 'Column');

        I know there is no free service available here, but I very much appreciate any help available. :-)
        --
        arc_of_descent

        I'm lazy, and I don't like to type.
        Phht. If you were really lazy, you'd've just typed "I'm lazy." instead.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (9)
As of 2024-04-19 06:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found