Re: [Dbix-class] Re: DateTime objects passed to search() are not supported properly

2012-09-20 Thread Peter Rabbitson
On Wed, Sep 19, 2012 at 07:06:19AM -0700, Bill Moseley wrote: > On Wed, Sep 19, 2012 at 3:36 AM, Peter Rabbitson wrote: > > > > > It never had a method to format it correctly in *all* cases. It can format > > it correctly 95% of the time (this is not really

Re: [Dbix-class] establishing relationship across databases

2012-09-20 Thread Peter Rabbitson
On Thu, Sep 20, 2012 at 11:18:41AM +0100, Sungsam Gong wrote: > Hi, > > I have been creating a manual relationship between tables (mysql > MyISAM) within the same database, which worked very well for my > purpose. > Just wondering whether it's possible to make a relationship between > two tables e

Re: [Dbix-class] Re: DateTime objects passed to search() are not supported properly

2012-09-20 Thread Peter Rabbitson
On Thu, Sep 20, 2012 at 12:56:30PM +0200, Alexander Hartmaier wrote: > On 2012-09-20 12:22, Peter Rabbitson wrote: > > On Wed, Sep 19, 2012 at 07:06:19AM -0700, Bill Moseley wrote: > >> On Wed, Sep 19, 2012 at 3:36 AM, Peter Rabbitson > >> wrote: > >> >

Re: [Dbix-class] DBIx::Class::Ordered changes.

2012-09-20 Thread Peter Rabbitson
On Thu, Sep 20, 2012 at 11:50:58AM +0100, Will Crawford wrote: > On 20 September 2012 11:19, Peter Rabbitson wrote: > > > I experimented with some stuff that is still on my disk, trying to set the > > nextpos to (SELECT pos ) + 1. It worked for most engines except for Pg

Re: [Dbix-class] Re: DateTime objects passed to search() are not supported properly

2012-09-20 Thread Peter Rabbitson
On Thu, Sep 20, 2012 at 12:44:31PM -0700, Bill Moseley wrote: > On Thu, Sep 20, 2012 at 3:22 AM, Peter Rabbitson wrote: > > > > > Precisely. The problem is that we can not invoke the correct IC::DT > > deflation routine to respect possible time_zone settings. The forma

Re: [Dbix-class] DBIx::Class::Ordered changes.

2012-09-20 Thread Peter Rabbitson
On Thu, Sep 20, 2012 at 12:23:51PM -0700, Bill Moseley wrote: > On Thu, Sep 20, 2012 at 4:06 AM, Peter Rabbitson wrote: > > > > > The reason Bill started this thread is that the above apparently did not > > work for him. I am now confused... > > > > Hi Peter

Re: [Dbix-class] SQL::Translator conversion from Class::Base to Moo

2012-09-23 Thread Peter Rabbitson
On Sun, Sep 23, 2012 at 09:37:43AM -0500, fREW Schmidt wrote: > As a followup to this, as things seem to have cooked sufficiently I have > cut a minor fix release (0.11013) and rebased ilmari's changes on that > and cut a dev release (0.11013_01.) Assuming there aren't any issues > from various sm

Re: [Dbix-class] Re: SQL::Translator conversion from Class::Base to Moo

2012-09-23 Thread Peter Rabbitson
On Sun, Sep 23, 2012 at 06:28:37PM +0100, Dagfinn Ilmari Mannsåker wrote: > Peter Rabbitson writes: > > > On Sun, Sep 23, 2012 at 09:37:43AM -0500, fREW Schmidt wrote: > >> As a followup to this, as things seem to have cooked sufficiently I have > >> cut a minor fix

Re: [Dbix-class] _no_scope_identity_query error

2012-10-11 Thread Peter Rabbitson
On Tue, Oct 09, 2012 at 11:26:57PM -0400, Paul Rogers wrote: > > > > > I'm running ActivePerl v5.16.1 on Win2008 R2 x64. Anyone see the below error > message before? Running same script on x86 machine produces no such error. > P:\test>perl "test.pl" > Can't locate object method "_no_scop

Re: [Dbix-class] CachedKids limitation

2012-10-26 Thread Peter Rabbitson
On Fri, Oct 26, 2012 at 11:26:59AM +0400, Dmitry Belyavsky wrote: > Greetings! > > We have found out that the number of CachedKids hash elements becomes > too big during the life cycle of the DBIx::Class object. > How can we limit it to avoid memory usage growth? > https://metacpan.org/module/DB

Re: [Dbix-class] A timestamp field is null when a record is created

2012-10-30 Thread Peter Rabbitson
On Tue, Oct 30, 2012 at 01:54:38PM +0100, Alexander Hartmaier wrote: > $obj->discard_changes; > because the database assigns the column value on insert but DBIC doesn't > fetch it from he db. Please do not use/recommend discard_changes() for this use-case. d_s() is too heavy as it refetches *ever

Re: [Dbix-class] Re: A timestamp field is null when a record is created

2012-10-31 Thread Peter Rabbitson
On Wed, Oct 31, 2012 at 04:44:54PM +0300, Eugene Yarmash wrote: > "discard_changes" is more general approach. For example it can be > used with "prefetch". . If anything discard_changes and prefetch are rather mutually exclusive. Can you clarify what do you mean? Cheers

Re: [Dbix-class] DBIx-Table-TestDataGenerator-0.001 released

2012-11-01 Thread Peter Rabbitson
On Wed, Oct 31, 2012 at 10:24:04PM +0100, "José Diaz Seng" wrote: > Hi, > > I spent some time reading documentation about DBIC Schema Loader and DBIC in > general (hard stuff for newcomers to DBIC...) and wrote a little program that > uses > Schema Loader to load the schema of a little SQLite te

Re: [Dbix-class] Re: A timestamp field is null when a record is created

2012-11-01 Thread Peter Rabbitson
On Wed, Oct 31, 2012 at 05:17:24PM +0300, Eugene Yarmash wrote: > >On Wed, Oct 31, 2012 at 04:44:54PM +0300, Eugene Yarmash wrote: > >>/ "discard_changes" is more general approach. For example it can be > >/>/ used with "prefetch". > >/ > >. If anything discard_changes and prefetch are rather mut

Re: [Dbix-class] DBIx::Class::Exceptions

2012-11-05 Thread Peter Rabbitson
On Fri, Nov 02, 2012 at 03:41:48PM +1100, Toby Corkindale wrote: > Hi, > It used to be the case (some versions ago) that if you died with an object > inside a txn_do() then the re-thrown error would still contain that object. > > However now it seems to be stringified on the way out. > > To give

Re: [Dbix-class] trying to figure out why DBIc query is slow

2012-11-08 Thread Peter Rabbitson
On Thu, Nov 08, 2012 at 10:55:03AM -0600, Frank Sheiness wrote: > Aaron, > > Thanks for your reply. There are differences between the queries, but I > have confirmed multiple times that using psql or a DBI script, both queries > return in under a second (with the same date ranges). But is that w

Re: [Dbix-class] rows error

2012-11-09 Thread Peter Rabbitson
On Fri, Nov 09, 2012 at 01:41:31PM +0100, Theo Bot wrote: > Hi, > > Can anybody tell me what is wrong with this? > $rs = $schema->resultset("Location")->search( > { > name => { like => '%' }, > }, > { > order_by => 'location_id', > rows

Re: [Dbix-class] rows error

2012-11-10 Thread Peter Rabbitson
On Sat, Nov 10, 2012 at 02:50:24PM +0100, Theo Bot wrote: > Peter > > I'm sorry it was my fault. I upgraded my DBIx::Class module, but I'm also > using a private instance of DBIx::Class::Storage::DBI . And that one wasn't > updated so I caused the issue myself. No problem. Could you share what is

Re: [Dbix-class] Re: [Catalyst] Session::Store::DBIC and session table (postgres)

2012-11-15 Thread Peter Rabbitson
On Thu, Nov 15, 2012 at 10:31:21AM -0300, Fernan Aguero wrote: > So, apparently the problem is calling delete() right on the resultset > object. For some reason that eludes me, DBIC is not fully qualifying the > table in this case. This is a known issue, RT#80015. Should be fixed shortly (hopefull

Re: [Dbix-class] test failures in latest DBIx::Class

2012-11-15 Thread Peter Rabbitson
On Thu, Nov 15, 2012 at 05:55:35PM +, David Cantrell wrote: > I'm getting a test failure in the latest DBIx::Class: > > # Failed test 'DBIx::Class::perlstring appears to have entered inheritance > chain by import into Class::Accessor::Grouped' > # at t/55namespaces_cleaned.t line 144. > #

Re: [Dbix-class] Re: [Catalyst] Session::Store::DBIC and session table (postgres)

2012-11-21 Thread Peter Rabbitson
On Thu, Nov 15, 2012 at 11:08:58AM -0300, Fernan Aguero wrote: > On Thu, Nov 15, 2012 at 10:38 AM, Peter Rabbitson > wrote: > > > On Thu, Nov 15, 2012 at 10:31:21AM -0300, Fernan Aguero wrote: > > > So, apparently the problem is calling delete() right on the resultse

Re: [Dbix-class] LEFT OUT JOIN with custom condition/bind value

2012-11-25 Thread Peter Rabbitson
On Sun, Nov 25, 2012 at 11:57:28PM +0900, Hailin Hu wrote: > Hi, Sven > > I'm afraid it is hard to define a conditional relationship with DBIx::Class. > But you can rewrite the condition in JOIN clause with WHERE clause in > most of cases. An inner join - yes. A left join - never. The WHERE and O

Re: [Dbix-class] LEFT OUT JOIN with custom condition/bind value

2012-11-25 Thread Peter Rabbitson
On Sat, Nov 24, 2012 at 04:26:37PM +0100, Sven Eppler wrote: > I know about the CODEREF-Option for defining Relationship-Conditions. > But they don't seem to solve my problem, right? Not entirely. The coderef is invoked every time a query is generated, and the contents of the coderef are made of p

Re: [Dbix-class] LEFT OUT JOIN with custom condition/bind value

2012-11-25 Thread Peter Rabbitson
On Sun, Nov 25, 2012 at 09:40:19PM +, Aaron Trevena wrote: > On 25 November 2012 15:27, Peter Rabbitson wrote: > > On Sat, Nov 24, 2012 at 04:26:37PM +0100, Sven Eppler wrote: > >> I know about the CODEREF-Option for defining Relationship-Conditions. > >> But

Re: [Dbix-class] ResultClass::HashRefInflator skipping last column on table joins

2012-11-25 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 07:15:33AM +, Jillian Rowe wrote: > Hello all, > > I am having trouble using DBIx::ResultClass::HashRefInflator on a result set > that has table joins. What you stated in the subject line is not possible - you are misdiagnosing your problem. Please provide *actual* se

Re: [Dbix-class] ResultClass::HashRefInflator skipping last column on table joins

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 08:31:31AM +, Jillian Rowe wrote: > > #for this particular case, sometimes this has an actual value > $c->stash(WHERE => undef); > > $c->log->debug(Dumper($c->stash->{FIELDS})); > $c->log->debug(Dumper($c->stash->{TABLES})); > > ##Gets me > $c->stash->{FI

Re: [Dbix-class] Autocommit => 0

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 12:23:17PM +0400, Dmitry Belyavsky wrote: > Greetings! > > What does the changelog string for 0.08127 > > - DBIx::Class now warns when the user erroneously supplies AutoCommit > => 0 to connect() > > mean? > > I use AutoCommit =>0 not erroneously but specially... > Usi

Re: [Dbix-class] Autocommit => 0

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 02:04:32PM +0400, Dmitry Belyavsky wrote: > Greetings! > > Thank you! > And what is the way to make this warning silent? It is undocumented... It is part of the warning itself[1] - docpatches to clarify this welcome (though said docpatches must continue to stress that it *

Re: [Dbix-class] ResultClass::HashRefInflator skipping last column on table joins

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 10:08:07AM +, Jillian Rowe wrote: > I was cutting and pasting from several logs, sorry about that. Lets start > fresh. > > SQL statement: > > SELECT me.PID, qdem.qdem0006, qdem.qdem0007, qdem.qdem0008, qdem.qdem0009, > qdem.qdem0010 FROM qpid me LEFT JOIN qdem qdem

Re: [Dbix-class] Autocommit => 0

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 04:14:18PM +0400, Dmitry Belyavsky wrote: > Greetings! > > I prefer to set AutoCommit to 0 because it helps to avoid extra commits > during debug just not writing the commit() function, whether I use > DBIx::Class or plain DBI. The same effect can be achieved in a much san

Re: [Dbix-class] Autocommit => 0

2012-11-26 Thread Peter Rabbitson
On Mon, Nov 26, 2012 at 10:02:48AM -0500, Len Jaffe wrote: > On Mon, Nov 26, 2012 at 8:17 AM, Peter Rabbitson wrote: > > > On Mon, Nov 26, 2012 at 04:14:18PM +0400, Dmitry Belyavsky wrote: > > > I prefer to set AutoCommit to 0 because it helps to avoid extra commits > &

Re: [Dbix-class] Get next val from sequence

2012-12-06 Thread Peter Rabbitson
On Wed, Dec 05, 2012 at 12:42:56PM -0800, Bill Moseley wrote: > I'm using Postgresql. Can someone pont me to docs on fetching nextval? There is no public interface for this, since everyone who asked for a generic "fetch sequence" API never delivered a proposal how it would actually work. The c

Re: [Dbix-class] Undetermined driver warning

2012-12-06 Thread Peter Rabbitson
On Sun, Dec 02, 2012 at 06:20:47AM +1300, Dan Horne wrote: > Hi > > After returning to some old code that worked fine, I find that the latest > version of DBIx::Class raises the following warning when my code's tests > are run: > > "This version of DBIC does not yet seem to supply a driver for yo

Re: [Dbix-class] Retrieving data from a link table

2012-12-10 Thread Peter Rabbitson
On Fri, Dec 07, 2012 at 04:53:06PM +0100, Ekki Plicht (DF4OR) wrote: > Hi. > Two tables with a many_to_many relation via a link table: > > Table of web pages: > table webpage(id, filename, ...) > > Table of images: > table images (id, filename, ...) > > Table linking pages and images: > table im

Re: [Dbix-class] exception_action fail after DBIC upgrade

2012-12-10 Thread Peter Rabbitson
On Mon, Dec 10, 2012 at 12:30:52PM +0400, Konstantin A. Pustovalov wrote: > Hello list! > > I'm using exception_action feature. Some of my tests fail after > upgrading 0.08196 -> 0.08204 > I have reduced test case to the following: http://paste.scsys.co.uk/217862 > exception_action is never get c

Re: [Dbix-class] Undetermined driver warning

2012-12-13 Thread Peter Rabbitson
On Thu, Dec 13, 2012 at 03:46:24PM +1300, Dan Horne wrote: > Hi > > Since the test doesn't require any database access I simply used a mock > object. But since most of the other tests do, I'll switch to DBD::SQLite You don't have to. As I said - I would like to *see* one test, which maybe wil

Re: [Dbix-class] Error with +columns

2012-12-14 Thread Peter Rabbitson
On Fri, Dec 14, 2012 at 12:48:22PM -0800, mpm wrote: > I am getting an error, that was not happening before: What version were you using before, and what version are you using now. ___ List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class I

Re: [Dbix-class] exception_action fail after DBIC upgrade

2012-12-18 Thread Peter Rabbitson
On Mon, Dec 17, 2012 at 07:31:27AM -0800, Bill Moseley wrote: > On Mon, Dec 10, 2012 at 1:09 AM, Peter Rabbitson wrote: > > > On Mon, Dec 10, 2012 at 12:30:52PM +0400, Konstantin A. Pustovalov wrote: > > > Hello list! > > > > > > I'm using exception

Re: [Dbix-class] Error with +columns

2012-12-18 Thread Peter Rabbitson
On Fri, Dec 14, 2012 at 12:48:22PM -0800, mpm wrote: > I am getting an error, that was not happening before: > > my $where_o={}; > my $attr_o={}; > my @og; > $where_o->{'me.m_id'}= $m_id; > $where_o->{'sp.is'}='y'; > p

Re: [Dbix-class] DBIC usage smoke/sanity check

2012-12-18 Thread Peter Rabbitson
On Sat, Dec 15, 2012 at 10:05:07AM -0800, Bill Moseley wrote: > I've been asked to add something to our build process that does some kind > of sanity check on the database. For example, make sure all columns > defined in the result class exist in the target database. > > I realize this won't cat

Re: [Dbix-class] order by field?

2012-12-18 Thread Peter Rabbitson
On Mon, Dec 17, 2012 at 11:04:22AM +0100, QE :: Felix Ostmann wrote: > I am doing such a order with the following SQL: > > ... > ORDER BY > (department = 'Marketing') DESC, > (department = 'Sales') DESC, > (department = 'Financial') DESC, > (department = 'IT') DESC, > (department = 'Oper

Re: [Dbix-class] Query is NOT created successfully.

2012-12-18 Thread Peter Rabbitson
On Mon, Dec 17, 2012 at 01:50:06PM -0800, dkim wrote: > Hello, > > When I use DBIx::Class::ResultSet::search() method with a complex query with > multiple joins, the query produced from DBIx::Class is not complete. Some > conditions are missing in the SQL query when I check the SQL. If I test it

Re: [Dbix-class] order by field?

2012-12-18 Thread Peter Rabbitson
On Tue, Dec 18, 2012 at 10:53:25AM +0200, Octavian Rasnita wrote: > From: "Peter Rabbitson" > > > On Mon, Dec 17, 2012 at 11:04:22AM +0100, QE :: Felix Ostmann wrote: > >> I am doing such a order with the following SQL: > >> > >> ... >

Re: [Dbix-class] order by field?

2012-12-18 Thread Peter Rabbitson
On Tue, Dec 18, 2012 at 10:53:25AM +0200, Octavian Rasnita wrote: > From: "Peter Rabbitson" > > > On Mon, Dec 17, 2012 at 11:04:22AM +0100, QE :: Felix Ostmann wrote: > >> I am doing such a order with the following SQL: > >> > >> ... >

Re: [Dbix-class] order by field?

2012-12-18 Thread Peter Rabbitson
On Tue, Dec 18, 2012 at 12:29:10PM +0200, Octavian Rasnita wrote: > From: "Peter Rabbitson" > > > > On Tue, Dec 18, 2012 at 10:53:25AM +0200, Octavian Rasnita wrote: > >> From: "Peter Rabbitson" > >> > >> > On Mon, Dec 17,

Re: [Dbix-class] DBIx::Class::Helper::ResultSet::Random and Oracle

2012-12-18 Thread Peter Rabbitson
On Wed, Dec 19, 2012 at 01:15:46AM +0100, "José Diaz Seng" wrote: > Hi Arthur Axel, > > motivated by your email (see below) I refactored my module, version 0.004 is > based on > DBIC (Schema Loader). > > I was doing some tests before the upload to CPAN and noticed that the rand() > method of

Re: [Dbix-class] Fwd: Sybase identity column value not being retrieved during create()

2013-01-09 Thread Peter Rabbitson
On Wed, Jan 09, 2013 at 10:27:52AM -0500, Phillip Moore wrote: > NOTE: I attempted to send the forwarded message below for the > holidays, but it got bounced. I've re-joined the mailing list, so > I'm hoping this one gets through this time Yep it did. For future reference you can always see

Re: [Dbix-class] Fwd: Sybase identity column value not being retrieved during create()

2013-01-09 Thread Peter Rabbitson
On Thu, Jan 10, 2013 at 04:54:22AM +1100, Peter Rabbitson wrote: > On Wed, Jan 09, 2013 at 10:27:52AM -0500, Phillip Moore wrote: > > NOTE: I attempted to send the forwarded message below for the > > holidays, but it got bounced. I've re-joined the mailing list, so > >

Re: [Dbix-class] Fwd: Sybase identity column value not being retrieved during create()

2013-01-09 Thread Peter Rabbitson
On Wed, Jan 09, 2013 at 01:50:09PM -0500, Phillip Moore wrote: > OK, I have verified that master passes the entire test suite with and > without defining DBICTEST_SYBASE_(DSN|USER|PASS). The only > difference is that I get a couple of warnings: This is a problem. It means that our test somehow b

Re: [Dbix-class] Fwd: Sybase identity column value not being retrieved during create()

2013-01-09 Thread Peter Rabbitson
On Wed, Jan 09, 2013 at 01:50:09PM -0500, Phillip Moore wrote: > We have a HUGE project that is blocking on this, so this is the top of > my personal problem list right now. A large portion of the Sybase storage code makes baby jesus cry hard enough to die from dehydration. I won't be able to look

Re: [Dbix-class] Fwd: Sybase identity column value not being retrieved during create()

2013-01-09 Thread Peter Rabbitson
On Wed, Jan 09, 2013 at 03:54:29PM -0500, Phillip Moore wrote: > Understood -- I'll be more than grateful for whatever help you might > be able to offer. > > Again, if there's anything you would like me to do to gather > additional diagnostics, just say the word. Actually it would help if there i

Re: [Dbix-class] Sybase ASE 15.7 Issue: Quoted Identifiers and compound SQL statements

2013-01-11 Thread Peter Rabbitson
On Fri, Jan 11, 2013 at 10:08:18AM -0500, Phillip Moore wrote: > I've been working with some of the Sybase experts at work, and they > have fed me a few ideas that helped me get to what I think it a pretty > significant clue. For context, this is a continuation of the recent > thread: > > S

Re: [Dbix-class] Sybase ASE 15.7 Issue: Quoted Identifiers and compound SQL statements

2013-01-11 Thread Peter Rabbitson
On Fri, Jan 11, 2013 at 11:56:31AM -0500, Phillip Moore wrote: > On Fri, Jan 11, 2013 at 11:30 AM, Peter Rabbitson > wrote: > > Please in the future make additions to the DBIC test suite itself. > > The mini-distro you submitted may be demonstrating the problem, but > >

Re: [Dbix-class] Caching a resultset?

2013-01-14 Thread Peter Rabbitson
On Sun, Jan 13, 2013 at 11:35:06PM -0500, Jesse Sheidlower wrote: > > I have a Catalyst app that very frequently (pretty much every request) > requires several DBIC resultsets that return a small number of values, > that very rarely change. I'm trying to cache this, so I can update the > cache whe

Re: [Dbix-class] Caching a resultset?

2013-01-14 Thread Peter Rabbitson
On Mon, Jan 14, 2013 at 09:26:04AM +0100, Alexander Hartmaier wrote: > The resultset has a ref to the schema which in turn has one to its > database connection which can't be serialized/cached. > After unfreezing it you have to link the $rs back to a schema with a > working database connection. > I

Re: [Dbix-class] Caching a resultset?

2013-01-14 Thread Peter Rabbitson
On Mon, Jan 14, 2013 at 06:30:42AM -0500, Jesse Sheidlower wrote: > On Mon, Jan 14, 2013 at 10:13:44PM +1100, Peter Rabbitson wrote: > > On Sun, Jan 13, 2013 at 11:35:06PM -0500, Jesse Sheidlower wrote: > > > > > > I have a Catalyst app that very frequently

Re: [Dbix-class] Caching a resultset?

2013-01-14 Thread Peter Rabbitson
On Sun, Jan 13, 2013 at 11:35:06PM -0500, Jesse Sheidlower wrote: > > I have a Catalyst app that very frequently (pretty much every request) > requires several DBIC resultsets that return a small number of values, > that very rarely change. I'm trying to cache this, so I can update the > cache whe

[Dbix-class] Review request - branch for_current/cumulative

2013-01-14 Thread Peter Rabbitson
Please review and if no issues found merge [1]. More stuff will be coming down the pipe in the next few days... hopefully. [1] https://github.com/dbsrgits/dbix-class/compare/master...for_current;cumulative ___ List: http://lists.scsys.co.uk/cgi-bin/mai

Re: [Dbix-class] Caching a resultset?

2013-01-14 Thread Peter Rabbitson
On Mon, Jan 14, 2013 at 11:07:34AM -0500, Jesse Sheidlower wrote: > On Tue, Jan 15, 2013 at 01:30:55AM +1100, Peter Rabbitson wrote: > > On Sun, Jan 13, 2013 at 11:35:06PM -0500, Jesse Sheidlower wrote: > > > > > > I have a Catalyst app that very frequently

Re: [Dbix-class] Caching a resultset?

2013-01-15 Thread Peter Rabbitson
On Tue, Jan 15, 2013 at 10:09:19AM -0500, Jesse Sheidlower wrote: > On Tue, Jan 15, 2013 at 05:18:06AM +1100, Peter Rabbitson wrote: > > On Mon, Jan 14, 2013 at 11:07:34AM -0500, Jesse Sheidlower wrote: > > > > > > > > So apart from the mystery around the

Re: [Dbix-class] Caching a resultset?

2013-01-15 Thread Peter Rabbitson
On Tue, Jan 15, 2013 at 05:12:12PM +0100, Alexander Hartmaier wrote: > On 2013-01-15 16:51, Peter Rabbitson wrote: > > On Tue, Jan 15, 2013 at 10:09:19AM -0500, Jesse Sheidlower wrote: > >> On Tue, Jan 15, 2013 at 05:18:06AM +1100, Peter Rabbitson wrote: > >>> On M

Re: [Dbix-class] Caching a resultset?

2013-01-16 Thread Peter Rabbitson
On Wed, Jan 16, 2013 at 11:03:43AM +0100, Alexander Hartmaier wrote: > On 2013-01-15 21:49, Peter Rabbitson wrote: > > On Tue, Jan 15, 2013 at 05:12:12PM +0100, Alexander Hartmaier wrote: > >> On 2013-01-15 16:51, Peter Rabbitson wrote: > >>> On Tue, Jan 15, 2

Re: [Dbix-class] Caching a resultset?

2013-01-16 Thread Peter Rabbitson
On Wed, Jan 16, 2013 at 02:51:59AM +1100, Peter Rabbitson wrote: > On Tue, Jan 15, 2013 at 10:09:19AM -0500, Jesse Sheidlower wrote: > > On Tue, Jan 15, 2013 at 05:18:06AM +1100, Peter Rabbitson wrote: > > > On Mon, Jan 14, 2013 at 11:07:34AM -0500, Jesse Sheidlower wrote: >

Re: [Dbix-class] Caching a resultset?

2013-01-16 Thread Peter Rabbitson
On Wed, Jan 16, 2013 at 02:47:19PM +0100, Alexander Hartmaier wrote: > I had NO idea that's already possible, thanks for the great pointers! Do > we want to include that in the Cookbook? There is no such thing as "too much documentation". Please go for it. Also see if you can do something about [1

Re: [Dbix-class] exception_action fail after DBIC upgrade

2013-01-20 Thread Peter Rabbitson
On Mon, Dec 10, 2012 at 08:09:48PM +1100, Peter Rabbitson wrote: > On Mon, Dec 10, 2012 at 12:30:52PM +0400, Konstantin A. Pustovalov wrote: > > Hello list! > > > > I'm using exception_action feature. Some of my tests fail after > > upgrading 0.08196 -> 0.082

Re: [Dbix-class] help needed in forming a 'and' and 'or' select query using DBIx::Class

2013-01-21 Thread Peter Rabbitson
On Fri, Jan 18, 2013 at 10:19:25AM -0800, Rajeev Prasad wrote: > Hello, >   > I am trying to build a query based on two column values as folows: >   > columnA = x  (one char, any char - not null) > columnB = zz _or_ x,xx,yyy,mm  (comma seperated values or just one value) >   >   > I am looking for

Re: [Dbix-class] Caching a resultset?

2013-01-21 Thread Peter Rabbitson
On Thu, Jan 17, 2013 at 01:06:43AM +1100, Peter Rabbitson wrote: > On Wed, Jan 16, 2013 at 02:47:19PM +0100, Alexander Hartmaier wrote: > > I had NO idea that's already possible, thanks for the great pointers! Do > > we want to include that in the Cookbook? > > There is

Re: [Dbix-class] exception_action fail after DBIC upgrade

2013-01-21 Thread Peter Rabbitson
On Mon, Jan 21, 2013 at 09:26:24PM +0400, Konstantin A. Pustovalov wrote: > On 20.01.2013 23:11, Peter Rabbitson wrote: > >On Mon, Dec 10, 2012 at 08:09:48PM +1100, Peter Rabbitson wrote: > >>On Mon, Dec 10, 2012 at 12:30:52PM +0400, Konstantin A. Pustovalov wrote: > >>

Re: [Dbix-class] exception_action fail after DBIC upgrade

2013-01-21 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 01:23:51AM +0400, Konstantin A. Pustovalov wrote: > > >>Hi! > >> > >>Sorry for being silent. Loong russian holidays, you know ) > >>But I have investigated a little. DBIC seems to not notice the > >>exception if it (exeption) stringifies to zero length string. That > >>was

Re: [Dbix-class] exception_action fail after DBIC upgrade

2013-01-22 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 10:49:18AM +, Dave Howorth wrote: > Peter Rabbitson wrote: > > Yes, except that it is a flawed assumption that folks check for > > "truthiness" of $@. In fact any code that does this (if ($@) { ... }) is > > arguably wrong. The o

Re: [Dbix-class] Re: Prefetch and join on different tables

2013-01-22 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 11:23:42AM -0300, Paula wrote: > I tried this, and in this case I get: > > [error] DBIx::Class::Row::get_column(): No such column 'h1' > > so in this case it is not executing prefetch You are missing something simple, yet non-obvious. Please supply the *entire* search()

Re: [Dbix-class] DBIx::Class with ODBC

2013-01-22 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 09:21:51AM -0800, stephenmoy wrote: > Hi, > > Has anyone gotten DBIx::Class to work with an Ingres database using an ODBC > driver? > > I get the following error on a simple search: > DBIx::Class::ResultSet::search(): DBI Exception: DBD::ODBC::db get_info > failed: [Ingres

Re: [Dbix-class] Re: DBIx::Class with ODBC

2013-01-22 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 10:04:17AM -0800, stephenmoy wrote: > > Please connect to the database using plain DBI and give us the > > output of: > > > $dbh->get_info( > >$DBI::Const::GetInfoType::GetInfoType{SQL_DBMS_NAME} > > ); > > Output is INGRES > Grumble. The error before means that the

Re: [Dbix-class] Re: Prefetch and join on different tables

2013-01-22 Thread Peter Rabbitson
On Tue, Jan 22, 2013 at 02:46:40PM -0300, Paula wrote: > OK this is the code: (in previous emails I used different names for the > tables to simplify them, here I am using the real names in my code: > molcfp=mc,molstat=mt,moldata=mdata) > > > $attr->{join}='molstat'; > $attr->{prefetch}='molcfp';

Re: [Dbix-class] Re: DBIx::Class with ODBC

2013-01-24 Thread Peter Rabbitson
On Thu, Jan 24, 2013 at 11:42:15AM -0800, stephenmoy wrote: > >> Can you please debug it and see why/how it fails (perhaps step through it > >> with the debugger or something). Then get us the actual info it > >> produces, and hopefully adding the extra informix driver won't be much > >> work. >

Re: [Dbix-class] Re: DBIx::Class with ODBC

2013-01-25 Thread Peter Rabbitson
On Fri, Jan 25, 2013 at 06:05:44AM -0800, stephenmoy wrote: > >> When you connect to a DSN we do not yet know how to > >> support you should see something similar to this: [1]. However you > >> claimed you saw this exception [2]. > > In my test, the following line: > my ( $student ) = $schema-

Re: [Dbix-class] Code Review - Duplicated columns with 'having'

2013-02-13 Thread Peter Rabbitson
On Wed, Feb 13, 2013 at 02:42:24PM -0200, André Walker wrote: > Hello, > > I have run into a bug when using an aggregate function and setting two or more > possible values to the same column in the 'having' clause. > (As per https://rt.cpan.org/Public/Bug/Display.html?id=83305#txn-1180741) Exce

[Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial - v0.08240

2013-02-14 Thread Peter Rabbitson
Greetings Almost 4 years[1] to the day of the first commits toying with the idea, the constructor rewrite / prefetch modernization project seems to be nearing completion. At least it passes enough tests to be deemed a CPAN experimental release candidate, which *should not* eat your data. So wha

[Dbix-class] Re: [DBIx-Class-Devel] [ANNOUNCE] A much faster DBIx::Class public trial - v0.08240

2013-02-14 Thread Peter Rabbitson
On Thu, Feb 14, 2013 at 01:09:39PM +0100, Alexander Hartmaier wrote: > My ResultClass of one of the Cat apps triggered [1] but doesn't seem to > cause harm. > > [1] DBIx::Class::ResultSet::all(): ResultClass > NAC::Web::NAC::Model::DBIC::ResultClass::API does not inherit from > DBIx::Class::Row an

Re: [Dbix-class] Re: DBIx::Class with ODBC

2013-02-19 Thread Peter Rabbitson
On Sat, Jan 26, 2013 at 01:18:40AM +1100, Peter Rabbitson wrote: > On Fri, Jan 25, 2013 at 06:05:44AM -0800, stephenmoy wrote: > > >> When you connect to a DSN we do not yet know how to > > >> support you should see something similar to this: [1]. However you &

[Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-20 Thread Peter Rabbitson
Greetings Another release of the experimental constructor rewrite just hit CPAN. Please grab and test 0.08241-TRIAL from our nearest mirror [1]. You can install the release in question by simply executing: cpan R/RI/RIBASUSHI/DBIx-Class-0.08241-TRIAL.tar.gz or cpanm http://cpan.metacpan.or

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-20 Thread Peter Rabbitson
On Wed, Feb 20, 2013 at 02:44:56PM +0100, Wolfgang Kinkeldei wrote: > Hi, > > I found one query in a current project that fails under 0.08241 but worked > until 0.08208 (0.08240 left untested). > > my join/columns combinations of do no longer work in combination with > Hashref-inflation. A mini

Re: [Dbix-class] Re: DBIx::Class with ODBC

2013-02-20 Thread Peter Rabbitson
On Wed, Feb 20, 2013 at 09:12:29AM -0500, Stephen Moy wrote: > Thanks for all your help, Peter. > > We contacted the folks at Ingres (Actian), and they confirmed their > ODBC driver had a slight issue (it didn't support SQL_DM_VER). They > are planning to add that in, but it might take a while. >

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-21 Thread Peter Rabbitson
On Wed, Feb 20, 2013 at 03:37:58PM +0100, Wolfgang Kinkeldei wrote: > Hi Peter, > > Am 20.02.2013 um 15:04 schrieb Peter Rabbitson: > > > On Wed, Feb 20, 2013 at 02:44:56PM +0100, Wolfgang Kinkeldei wrote: > >> Hi, > >> > >> I found one query in a

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-22 Thread Peter Rabbitson
On Fri, Feb 22, 2013 at 11:23:50AM +, Will Crawford wrote: > It would probably be more intuitive to return something like: > > { > element => { > concept => { concept_id => nnn, foldername => 'xxx' }, > ... > }, > ... > } > > ? At first glance yes. The problem her

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-22 Thread Peter Rabbitson
On Fri, Feb 22, 2013 at 11:45:54AM +, Will Crawford wrote: > On 22 February 2013 11:36, Peter Rabbitson wrote: > > > > At first glance yes. The problem here is that you are incorrectly > > assuming that given 'concept.concept_id' one can simply infer we are

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-22 Thread Peter Rabbitson
On Fri, Feb 22, 2013 at 11:05:53PM +1100, Peter Rabbitson wrote: > . . . the map is strictly mirroring the > current relationship graph of your schema. To clarify this bit as it is in contradiction with http://lists.scsys.co.uk/pipermail/dbix-class/2013-February/09.html The old be

Re: [Dbix-class] "search on row->has_many fails if row has prefetch join" after 0.08196 -> 0.08206 upgrade

2013-02-22 Thread Peter Rabbitson
On Fri, Feb 22, 2013 at 04:46:46PM +, Chisel wrote: > At work we had to freeze our DBIC at 0.08196 until the prefetch/namespace > bug was fixed ... which it was recently. > > Internally we've built the new perl+cpandeps RPM including DBIx::Class > 0.08206. Things are looking great for the pref

Re: [Dbix-class] "search on row->has_many fails if row has prefetch join" after 0.08196 -> 0.08206 upgrade

2013-02-23 Thread Peter Rabbitson
On Sat, Feb 23, 2013 at 03:58:20AM +1100, Peter Rabbitson wrote: > On Fri, Feb 22, 2013 at 04:46:46PM +, Chisel wrote: > > At work we had to freeze our DBIC at 0.08196 until the prefetch/namespace > > bug was fixed ... which it was recently. > > > > Internal

Re: [Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round two - v0.08241

2013-02-24 Thread Peter Rabbitson
On Sat, Feb 23, 2013 at 10:14:56PM -0800, Bill Moseley wrote: > On Wed, Feb 20, 2013 at 5:44 AM, Wolfgang Kinkeldei > wrote: > > > > > The error message reported reads: > > > > "DBIx::Class::ResultSet::all(): Inflation into non-existent relationship > > 'concept' of 'Subelement' requested, check t

Re: [Dbix-class] "the apparent complexity of it all"

2013-02-24 Thread Peter Rabbitson
On Sun, Feb 24, 2013 at 07:33:56PM +0100, Lars Dɪᴇᴄᴋᴏᴡ 迪拉斯 wrote: > This is a follow-up to > <http://blogs.perl.org/users/ross_attrill/2013/02/dbixdatamodel---elegant-database-interaction-with-perl.html#comment-367206>. > > Peter Rabbitson ✍: > > Steven Haryanto ✍: >

Re: [Dbix-class] "the apparent complexity of it all"

2013-02-25 Thread Peter Rabbitson
On Sun, Feb 24, 2013 at 11:05:37PM -0600, Mike South wrote: > If you do this on github I will work with you on the usability testing Just on a tangent - DBIC itself has a github mirror, and pull requests are actively acted upon. So if you can think of one-off doc-fixes, or even rewriting larger

Re: [Dbix-class] PostgreSQL & schema

2013-02-27 Thread Peter Rabbitson
On Wed, Feb 27, 2013 at 10:04:34AM -0500, Diab Jerius wrote: > I'm trying to organize database objects using schema. My primary server > backend is Postgres. The DBIC Pg storage docs indicate that it supports > schema, but there's not much information anywhere that I can find in the > DBIC docume

Re: [Dbix-class] PostgreSQL & schema

2013-02-27 Thread Peter Rabbitson
On Wed, Feb 27, 2013 at 10:04:34AM -0500, Diab Jerius wrote: > I'm trying to organize database objects using schema. My primary server > backend is Postgres. The DBIC Pg storage docs indicate that it supports > schema, but there's not much information anywhere that I can find in the > DBIC docume

Re: [Dbix-class] How do I select bound functions with as 'as' name in the column

2013-03-08 Thread Peter Rabbitson
On Fri, Mar 08, 2013 at 02:05:19PM +, Robert Rothenberg wrote: > > I am trying to run a DBIx::Class query on a PostGIS function with binders, > with the attributes of the search query having something like: > > { > 'as' => [ > 'id', > 'name', > 'location', > 'distance_f

[Dbix-class] [ANNOUNCE] A much faster DBIx::Class public trial round three - v0.08242

2013-03-10 Thread Peter Rabbitson
Greetings Yet another release of DBIC featuring the experimental constructor rewrite just hit CPAN. Please grab and test 0.08242-TRIAL from your nearest mirror [1]. You can install the release in question by simply executing: cpan R/RI/RIBASUSHI/DBIx-Class-0.08242-TRIAL.tar.gz or cpanm

Re: [Dbix-class] Re: "search on row->has_many fails if row has prefetch join", after 0.08196 -> 0.08206 upgrade

2013-03-10 Thread Peter Rabbitson
On Sun, Mar 10, 2013 at 02:36:49PM +, Colin Dearing wrote: > I have tested this in our test suite with master at that time and > can confirm it passes. Aye, we shipped it as 0.08209 since - too risky to let langish. By the way 0.08242 is available - please test and report ;) http://lists.scsys

Re: [Dbix-class] DBIx::Class::ResultClass::HashRefInflator and JSON::XS expanding numbers as strings

2013-03-15 Thread Peter Rabbitson
On Fri, Mar 15, 2013 at 09:48:13AM +, Robert Rothenberg wrote: > I have a PostgreSQL database that I run queries on, then use > > $rs->result_class('DBIx::Class::ResultClass::HashRefInflator'); > > and send [ $rs->all ] to JSON::XS for serialization in a RESTful interface. > > It works wel

Re: [Dbix-class] Re: Support for inline where (left join with extra condition)

2013-03-15 Thread Peter Rabbitson
On Thu, Mar 14, 2013 at 12:13:17AM +, brew wrote: > Yes that is a good improvement, thanks. > > For my case I would need the year to be a bind variable which > doesn't look like it is possible The "proper" way to do this will come at some point (frew: poke poke), it just isn't as easy as it

Re: [Dbix-class] Is columns to cols as +columns is to +cols

2013-03-18 Thread Peter Rabbitson
On Mon, Mar 18, 2013 at 05:54:53PM +, Darius Jokilehto wrote: > Hello, > > Just wanted to point out an issue I ran with cols/+cols when chaining a > couple of DBIC queries. > > I was trying to do the following: > > $schema->resultset('CD')->search({}, { cols => 'me.cola'})->search{}, { > '

<    1   2   3   4   5   6   7   8   9   >