Re: [Dbix-class] Advise

2006-07-25 Thread Christopher H. Laco
> __PACKAGE__->table(\'(SELECT DISTINCT state FROM fucked_up_table)'); > __PACKAGE__->add_columns('state'); > __PACKAGE__->set_primary_key('state'); Oh gawd. My eyes. MY EYES That's like a DBIC drive-by shooting. :-) -=Chris signature.asc Description: OpenPGP digital signature

Re: [Dbix-class] Advise

2006-07-25 Thread Matt S Trout
Duncan Ferguson wrote: > On Mon, 2006-07-24 at 19:50 +0100, Matt S Trout wrote: >> How about just building a set of classes all with the same ->table but >> different subsets of the columns? source name != table name, specifically to >> avoid tying you down in situations like this. > > Thought a

Re: [Dbix-class] Advise

2006-07-25 Thread Duncan Ferguson
On Mon, 2006-07-24 at 19:50 +0100, Matt S Trout wrote: > How about just building a set of classes all with the same ->table but > different subsets of the columns? source name != table name, specifically to > avoid tying you down in situations like this. Thought about that (as in my original ema

Re: [Dbix-class] Advise

2006-07-24 Thread Matt S Trout
Duncan J Ferguson wrote: > Its an oracle database which I have no control over. I may be able to > get some views created for me (if I speak nicely to our DBA's), but > doesnt that still leave the problem of the primary keys? Can you have > primary keys on views like that? How about just buildin

Re: [Dbix-class] Advise

2006-07-24 Thread Brandon Black
On 7/24/06, Duncan J Ferguson <[EMAIL PROTECTED]> wrote: > Its an oracle database which I have no control over. I may be able to > get some views created for me (if I speak nicely to our DBA's), but > doesnt that still leave the problem of the primary keys? Can you have > primary keys on views li

Re: [Dbix-class] Advise

2006-07-24 Thread Duncan J Ferguson
Its an oracle database which I have no control over. I may be able to get some views created for me (if I speak nicely to our DBA's), but doesnt that still leave the problem of the primary keys? Can you have primary keys on views like that? Duncs On Mon, 2006-07-24 at 20:33 +0300, Bogdan Luca

Re: [Dbix-class] Advise

2006-07-24 Thread Bogdan Lucaciu
On Mon, 2006-07-24 at 15:52 +, Duncan Ferguson wrote: > Wotcha, > > I have set up a perl module using Class::DBI to access a mysql > database of my own design at my work. Then 2 things happened. The > first was I discovered DBIx::Class, and the second is that the data > source I was using (a

[Dbix-class] Advise

2006-07-24 Thread Duncan Ferguson
Wotcha,I have set up a perl module using Class::DBI to access a mysql database of my own design at my work.  Then 2 things happened.  The first was I discovered DBIx::Class, and the second is that the data source I was using (an excel spreadsheet which I import into my DB) is being imported into a