I had the same message last week.
It happens when your Result(Set) object loses its schema.
That might happen because of freeze/thaw, in my case because of
Parallel::Iterator which does use Storable internally.

The fix is to insert this line before you serialize the object:

# to let DBIC automatically pick up the correct schema in the child
# process after Storable freezed/thawed the result objects
local $DBIx::Class::ResultSourceHandle::thaw_schema =
$rs->result_source->schema;

Am 2011-07-18 17:35, schrieb Ben Tilly:
Could you show the code that fails?

I don't know DBIx::Class that well, but my gut feeling is that you
failed to do something basic like call
$schema->connect(@connect_info).

My usual way of debugging this sort of problem is to start with the
example code from the documentation.  Get that to work exactly.  Then
start trying to step by step modify it to the code that is broken.  At
some change it will break.  And when it does, I'll learn what I am
doing wrong.

On Mon, Jul 18, 2011 at 4:12 AM, Gordon Stewart
<gor...@gordonstewart.co.uk>  wrote:
Hi



When I call create on a result set I get the following error



Unable to perform storage-dependent operations with a detached result source
(source '_unnamed_' is not associated with a schema).



I am using the most up to date version of DBIx::Class.  I am also using it
with a MySQL backend.



Is there a setting I need to set so this error messages goes away and insert
records into the database.



Regards



Gordon

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive:
http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk

*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
T-Systems Austria GesmbH   Rennweg 97-99, 1030 Wien
Handelsgericht Wien, FN 79340b
*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
Notice: This e-mail contains information that is confidential and may be 
privileged.
If you are not the intended recipient, please notify the sender and then
delete this e-mail immediately.
*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk

Reply via email to