Jump to content

The ultimate community for Ruby on Rails developers.


Photo

AS400 Statement Invalid


  • Please log in to reply
No replies to this topic

#1 Bob Kendall

Bob Kendall

    Signalman

  • Members
  • 19 posts

Posted 29 April 2014 - 05:56 PM

Hi There, 

I am running an app with an AS400 for the database. in the development environment I am getting the following error: 37000 (-104) [IBM][iSeries Access ODBC Driver][DB2 UDB]SQL0104 - Token ` was not valid. Valid tokens: ( TABLE LATERAL <IDENTIFIER>.

 

/usr/local/ruby/lib/ruby/gems/1.9.1/gems/activerecord-odbc-adapter-2.0/lib/active_record/connection_adapters/odbc_adapter.rb:1519:in `rescue in select'
/usr/local/ruby/lib/ruby/gems/1.9.1/gems/activerecord-odbc-adapter-2.0/lib/active_record/connection_adapters/odbc_adapter.rb:1514:in `select'
/usr/local/ruby/lib/ruby/gems/1.9.1/gems/activerecord-odbc-adapter-2.0/lib/active_record/connection_adapters/odbc_adapter.rb:770:in `select_all'
/usr/local/ruby/lib/ruby/gems/1.9.1/gems/activerecord-2.3.10/lib/active_record/base.rb:665:in `find_by_sql'
/var/www/onlineordering.coastalpet.com/app/models/item.rb:183:in `filter_categories'
/var/www/onlineordering.coastalpet.com/app/controllers/products_controller.rb:6:in `index'

 

here is the revelvant code for that above two pages:

 

/var/www/onlineordering.coastalpet.com/app/models/item.rb:183:in `filter_categories' = 

 
s = Item.find_by_sql [sql, upc_rule, query_account_number, upc_rule, query_account_number, upc_rule, query_account_number, upc_rule, query_account_number, upc_rule, query_account_number, upc_rule, query_account_number, upc_rule, query_account_number]
 
 

/var/www/onlineordering.coastalpet.com/app/controllers/products_controller.rb:6:in `index' = @categories = Item.filter_categories(session[:upc_rule], session[:query_account_number])

 

I am looking for thoughts on the error Token ` was not valid. Valid tokens: ( TABLE LATERAL <IDENTIFIER>. as I am not familiar with this error.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users