Keep gettting errors using Sequel ODBC::Error: 37000 (170) [ODBC SQL Server Driv er][SQL Server]Line

i am trying to connect to MSSQL server from xP

i have the following problem for any sql. pl help
ODBC::Error: 37000 (170) [Microsoft][ODBC SQL Server Driv
er][SQL Server]Line 1: Incorrect syntax near ‘1’.

D:\Documents and Settings>irb
irb(main):001:0> require ‘odbc’
=> true
irb(main):002:0> require ‘Sequel’
=> true
<c(‘LPM’, :user=>‘resum’, :password=>‘ms_0416’)
=> #<Sequel::ODBC::Database: “odbc:resum:ms_04166@/LPM”>
irb(main):004:0> require ‘rubygems’
=> false
irb(main):005:0>
a=Sequel.odbc(‘LPM’, :user=>‘resum’, :password=>‘ms_04166>
=> #<Sequel::ODBC::Database: “odbc:resum:ms_0416@/LPM”>
irb(main):007:0> a.connect(‘LPM’)
=> #ODBC::Database:0x2d54990
irb(main):008:0> a.tables
Sequel::NotImplemented: #tables should be overridden by adapters
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/database
/query.rb:185:in tables' from (irb):8 irb(main):009:0> ds=Sequel.odbc('LPM', :user=>'resum', :password=>'ms_0416> => #<Sequel::ODBC::Database: "odbc:resum:ms_04166@/LPM"> irb(main):010:0> ds.connect('LPM') => #<ODBC::Database:0x35e5e10> irb(main):011:0> DB=Sequel.odbc('LPM', :user=>'resum', :password=>'ms_0416> => #<Sequel::ODBC::Database: "odbc:resum:ms_04166@/LPM"> irb(main):012:0> DB.connect('LPM') => #<ODBC::Database:0x35ae1c0> irb(main):013:0> ds=DB[:ProblemTable] => #<Sequel::ODBC::Dataset: "SELECT * FROM \"PROBLEMTABLE\""> irb(main):014:0> ds.count Sequel::DatabaseError: ODBC::Error: 37000 (170) [Microsoft][ODBC SQL Server Driv er][SQL Server]Line 1: Incorrect syntax near '1'. from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/adapters /odbc.rb:52:inrun’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/adapters
/odbc.rb:52:in execute' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/database /logging.rb:28:inlog_yield’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/adapters
/odbc.rb:52:in execute' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/connecti on_pool/threaded.rb:84:inhold’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/database
/connecting.rb:226:in synchronize' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/adapters /odbc.rb:50:inexecute’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/dataset/
actions.rb:541:in execute' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/adapters /odbc.rb:92:infetch_rows’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/dataset/
actions.rb:123:in each' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/dataset/ actions.rb:449:insingle_record’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/dataset/
actions.rb:457:in single_value' from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/ sequel/dataset/ actions.rb:202:inget’
from C:/Ruby187/lib/ruby/gems/1.8/gems/sequel-3.23.0/lib/
sequel/dataset/
actions.rb:96:in `count’
from (irb):14
from :0

Add the :db_type=>‘mssql’ option to the Sequel.connect call if you are
connecting to SQL Server.

Jeremy