[Dbix-class] Oracle Built-In Functions

2010-08-04 Thread Duncan Garland
Hi, I'm struggling to persuade DBIx::Class to use simple Oracle built-ins such as SYSDATE, DECODE and NVL. Eg UPDATE table1 SET date_updated = SYSDATE, destination = NVL( $destination, 'home' ) WHERE ... ; $rs-date_updated( 'SYSDATE' ); Doesn't work, nor can any variation on a theme that I

Re: [Dbix-class] Oracle Built-In Functions

2010-08-04 Thread Андрей Костенко
$rs-date_updated( \‘SYSDATE’ ); On Wed, Aug 4, 2010 at 1:25 PM, Duncan Garland duncan.garl...@motortrak.com wrote: Hi, I’m struggling to persuade DBIx::Class to use simple Oracle built-ins such as SYSDATE, DECODE and NVL. Eg UPDATE table1 SET date_updated = SYSDATE, destination = NVL(

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread vdg
On Tue, Aug 3, 2010 at 10:17 PM, Ian dbix-cl...@iandocherty.com wrote: Nice one v. Always good to see different implementations. My first impressions below. As the author of DBIx::Class::Tree::NestedSet I tried to ensure that it contained the same method names where possible as other similar

RE: [Dbix-class] Oracle Built-In Functions

2010-08-04 Thread Duncan Garland
Hi Rob, Doing it in perl is a work-around not a solution. There are lots of built-in function which may need to be used. However, you and Andrey seem to be on the right lines with the reference. \'SYSDATE' works. The following also works: $v[0]-update( { date_to = \'DECODE( \'apples\',

Re: [Dbix-class] missing 'many-to-many' relationship

2010-08-04 Thread fREW Schmidt
On Wed, Aug 4, 2010 at 7:34 AM, Steve st...@matsch.com wrote: Hi all, I am bewildered as to why my 'many_to_many' relationship is being ignored. I get an error when trying to use the relationship because it 'does not exist', and clearly it doesn't. WHY? My result classes are 'User.pm',

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread fREW Schmidt
I note you use the term 'ascendants' which is not a real word and so would be confusing. Is this the same as 'ancestors'? If so then it would be best to use ancestors since that is a word know by other people and it keeps it consistent with other similar modules. Are you sure? I found

Re: [Dbix-class] missing 'many-to-many' relationship

2010-08-04 Thread Steve
On 8/4/2010 10:46 AM, fREW Schmidt wrote: On Wed, Aug 4, 2010 at 7:34 AM, Steve st...@matsch.com mailto:st...@matsch.com wrote: Hi all, I am bewildered as to why my 'many_to_many' relationship is being ignored. I get an error when trying to use the

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread Ashley Pond V
On Wed, Aug 4, 2010 at 7:50 AM, fREW Schmidt fri...@gmail.com wrote: I note you use the term 'ascendants' which is not a real word and so would be confusing. Is this the same as 'ancestors'? If so then it would be best to use ancestors since that is a word know by other people and it keeps it

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread Rob Kinyon
On Wed, Aug 4, 2010 at 12:10, Ashley Pond V a...@sedition.com wrote: On Wed, Aug 4, 2010 at 7:50 AM, fREW Schmidt fri...@gmail.com wrote: I note you use the term 'ascendants' which is not a real word and so would be confusing. Is this the same as 'ancestors'? If so then it would be best to use

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread Len Jaffe
On Wed, Aug 4, 2010 at 12:19 PM, Rob Kinyon rob.kin...@gmail.com wrote: Except ascendant means rising. ancestor and descendant are the proper terms for tree-walking. ascendant is not the right term. Antecedant anybody? -- lenja...@jaffesystems.com 614-404-4214 Scoutmaster Troop 156 -

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread Ram Dobson
ascendant DOES also mean ancestor. but that's a much less used meaning in english... rising is what people think ascendant means. i wasn't aware of the second definition until i looked at the dictionary myself... so ascendant is probably not the clearest choice. people use ancestor a

Re: [Dbix-class] missing 'many-to-many' relationship

2010-08-04 Thread fREW Schmidt
So to be clear, you are saying that you added the roles many to many in user and you do $user-roles and get that error? I'm guessing you did something like $user-related_resultset('roles'), which wouldn't work since technically m2m isn't a relationship. That's exactly what I'm doing!

Re: [Dbix-class] missing 'many-to-many' relationship

2010-08-04 Thread Len Jaffe
On Wed, Aug 4, 2010 at 1:04 PM, fREW Schmidt fri...@gmail.com wrote: Anyone wanna chime in on why m2m isn't a real rel? Because an m2m relationship is an model of two one-to-many relationships which share a table. I expect that related_resultset() could be made to handle m2m relationships

Re: [Dbix-class] DBIx::Class::Tree::Fast

2010-08-04 Thread Ian
On 04/08/2010 17:43, Len Jaffe wrote: On Wed, Aug 4, 2010 at 12:19 PM, Rob Kinyon rob.kin...@gmail.com mailto:rob.kin...@gmail.com wrote: Except ascendant means rising. ancestor and descendant are the proper terms for tree-walking. ascendant is not the right term. Antecedant

Re: [Dbix-class] Oracle Built-In Functions

2010-08-04 Thread Dan Horne
On 4 August 2010 22:25, Duncan Garland duncan.garl...@motortrak.com wrote: Hi, I’m struggling to persuade DBIx::Class to use simple Oracle built-ins such as SYSDATE, DECODE and NVL. Eg UPDATE table1 SET date_updated = SYSDATE, destination = NVL( $destination, ‘home’ ) WHERE ... ;

[Dbix-class] Improved resultset iterators

2010-08-04 Thread Toby Corkindale
Hi, I posted this to the list in May, just looking for confirmation that the API I had in mind was correct, before implementing it. (Since my first, implemented suggestion had been shot down, and I'd rather nail the spec down before coding it again.) No response at the time, but I thought I'd