Weird postgres adapter error

I just ported my Rails app from OSX/Linux to Windows XP for the first
time. I am running PostgreSQL 8.0 and the postgres-pr 4.0 adapter.
Some of the queries in my Rails app work, but for others I get a weird
error:

ArgumentError: Invalid Ruby/cstring: select sa.name as activity_name,
max(sah.created_at) as created_at
from site_activity_histories sah, site_activities sa
where sah.user_id = 17
and sah.site_activity_id = sa.id
and sa.viewable = true
group by activity_name
order by created_at desc
……
c:/development/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/abstract_adapter.rb:88:in
log' c:/development/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/postgresql_adapter.rb:137:inexecute’
c:/development/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/postgresql_adapter.rb:351:in
select' c:/development/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/postgresql_adapter.rb:118:inselect_all’
c:/development/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb:431:in
`find_by_sql’

Obviously, I am not getting this error in OSX/Linux. Anyone have any
ideas what is happening? Is there a better postgres adapter for
Windows?

thanks,
Jeff