Rake and Unitizialized Constants when RAIL_ENV is specified

Hi guys,
I'm having a problem with rake and rails 2.3.5
When I use any model inside db/seeds.rb or in any rake task and the
RAILS_ENV var is specified, I get the error:
uninitialized constant ModelName

Any clues?

Thanks a lot in advance.