aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2005-02-23 17:03:12 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2005-02-23 17:03:12 +0000
commit1dc0b2a96095695fabd9210a401484cd5b82146f (patch)
tree8d488126e7dea8b1d5681816e254e3c83ed61be1 /activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb
parent85fa238bca9e01eb1816cb85f4d67f16f55c189e (diff)
downloadrails-1dc0b2a96095695fabd9210a401484cd5b82146f.tar.gz
rails-1dc0b2a96095695fabd9210a401484cd5b82146f.tar.bz2
rails-1dc0b2a96095695fabd9210a401484cd5b82146f.zip
Added documentation for database adapters to visible RDoc
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@771 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb')
-rw-r--r--activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb38
1 files changed, 18 insertions, 20 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb b/activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb
index 7bddba9b5b..d221f99be3 100644
--- a/activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb
+++ b/activerecord/lib/active_record/connection_adapters/sqlserver_adapter.rb
@@ -5,24 +5,6 @@ require 'active_record/connection_adapters/abstract_adapter'
# Author: Joey Gibson <joey@joeygibson.com>
# Date: 10/14/2004
#
-# REQUIREMENTS:
-#
-# This adapter will ONLY work on Windows systems, since it relies on Win32OLE, which,
-# to my knowledge, is only available on Window.
-#
-# It relies on the ADO support in the DBI module. If you are using the
-# one-click installer of Ruby, then you already have DBI installed, but
-# the ADO module is *NOT* installed. You will need to get the latest
-# source distribution of Ruby-DBI from http://ruby-dbi.sourceforge.net/
-# unzip it, and copy the file src/lib/dbd_ado/ADO.rb to
-# X:/Ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb (you will need to create
-# the ADO directory). Once you've installed that file, you are ready to go.
-#
-# This module uses the ADO-style DSNs for connection. For example:
-# "DBI:ADO:Provider=SQLOLEDB;Data Source=(local);Initial Catalog=test;User Id=sa;Password=password;"
-# with User Id replaced with your proper login, and Password with your
-# password.
-#
# I have tested this code on a WindowsXP Pro SP1 system,
# ruby 1.8.2 (2004-07-29) [i386-mswin32], SQL Server 2000.
#
@@ -128,8 +110,24 @@ module ActiveRecord
end
- class SQLServerAdapter < AbstractAdapter # :nodoc:
-
+ # This adapter will ONLY work on Windows systems, since it relies on Win32OLE, which,
+ # to my knowledge, is only available on Window.
+ #
+ # It relies on the ADO support in the DBI module. If you are using the
+ # one-click installer of Ruby, then you already have DBI installed, but
+ # the ADO module is *NOT* installed. You will need to get the latest
+ # source distribution of Ruby-DBI from http://ruby-dbi.sourceforge.net/
+ # unzip it, and copy the file <tt>src/lib/dbd_ado/ADO.rb</tt> to
+ # <tt>X:/Ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb</tt> (you will need to create
+ # the ADO directory). Once you've installed that file, you are ready to go.
+ #
+ # Options:
+ #
+ # * <tt>:host</tt> -- Defaults to localhost
+ # * <tt>:username</tt> -- Defaults to sa
+ # * <tt>:password</tt> -- Defaults to nothing
+ # * <tt>:database</tt> -- The name of the database. No default, must be provided.
+ class SQLServerAdapter < AbstractAdapter
def select_all(sql, name = nil)
add_limit!(sql, nil)
select(sql, name)