error in rails 1.2.3 activerecord

i'm a rails nuby so i don't know where to fix this in the activerecord

there is no such column in the sys.view.user_constraints.
SELECT uc.index_name FROM user_constraints uc WHERE uc.constraint_type =

It would help to see the source from which the tables are constructed
(SQL, migrations,...)

this prevents me from doing a rake test:functionals in below....

C:\railsspace>c:\ruby186\ruby\bin\ruby c:\ruby186\ruby\bin\rake
test:functionals --trace
(in C:/railsspace)
** Invoke test:functionals (first_time)


** Execute db:schema:load
rake aborted!
./db/schema.rb:9: syntax error, unexpected tIDENTIFIER, expecting kDO or
'{' or

        [ rake...]

c:/ruby186/ruby/bin/rake:16:in `load'

So this is your schema.rb??

# This file is autogenerated. Instead of editing this file, please use
# migrations feature of ActiveRecord to incrementally modify your
database, and
# then regenerate this schema definition.

ActiveRecord::Schema.define(:version => 2) do

# Could not dump table "users" because of following
# OCIError: ORA-00904: invalid column name: SELECT

This is Oracle? I'm unfamiliar with that.

lower(i.index_name) as index_name, i.uniqueness, lower(c.column_name) as
              FROM user_indexes i, user_ind_columns c
             WHERE i.table_name = 'USERS'
               AND c.index_name = i.index_name
               AND i.index_name NOT IN (SELECT uc.index_name FROM
user_constraints uc WHERE uc.constraint_type = 'P')
              ORDER BY i.index_name, c.column_position


It's hard (for me) to tell where this is coming from without a bit more
info on how your tables are declared.