in reply to out of memory exception

Don't have an answer for you. I just want to point out that you keep saying DBIx when you mean DBIx::Class. They aren't the same--DBIx:: is a namespace with all kinds of unrelated things in it--and you'll get better answers if you give the right name. Many users, myself included, abbreviate it DBIC.