Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
1482 lines (744 sloc) 49.8 KB
=== HEAD
* Support bitwise operators for NumericExpressions: &, |, ^, ~, <<, >> (jeremyevans)
* No longer raise an error for Dataset#filter(true) or Dataset#filter(false) (jeremyevans)
* Allow Dataset #filter, #or, #exclude and other methods that call them to use both the block and regular arguments (jeremyevans)
* ParseTree support is now officially deprecated, use Sequel.use_parse_tree = false to use the expression (blockless) filters inside blocks (jeremyevans)
* Remove :pool_reuse_connections ConnectionPool/Database option, MySQL users need to be careful with nested queries (jeremyevans)
* Allow Dataset#graph :select option to take an array of columns to select (jeremyevans)
* Allow Dataset#to_hash to be called with only one argument, allowing for easy creation of lookup tables for a single key (jeremyevans)
* Allow join_table to accept a block providing the aliases and previous joins, that allows you to specify arbitrary conditions properly qualified (jeremyevans)
* Support NATURAL, CROSS, and USING joins in join_table (jeremyevans)
* Make sure HAVING comes before ORDER BY, per the SQL standard and at least MySQL, PostgreSQL, and SQLite (juco)
* Add cast_numeric and cast_string methods for use in the Sequel DSL, that have default types and wrap the object in the correct class (jeremyevans)
* Add Symbol#qualify, for adding a table/schema qualifier to a column/table name (jeremyevans)
* Remove Module#metaprivate, since it duplicates the standard Module#private_class_method (jeremyevans)
* Support the SQL CASE expression via Array#case and Hash#case (jeremyevans)
* Support the SQL EXTRACT function: :date.extract(:year) (jeremyevans)
* Convert numeric fields to BigDecimal in PostgreSQL adapter (jeremyevans)
* Add :decimal fields to the schema parser (jeremyevans)
* The expr argument in join table now allows the same argument as filter, so it can take a string or a blockless filter expression (brushbox, jeremyevans)
* No longer assume the expr argument to join_table references the primary key column (jeremyevans)
* Rename the Sequel.time_class setting to Sequel.datetime_class (jeremyevans)
* Add savepoint/nesting support to postgresql transactions (elven)
* Use the specified table alias when joining a dataset, instead of the automatically generated alias (brushbox)
=== 2.0.1 (2008-06-04)
* Have PostgreSQL money type use BigDecimal instead of Float (jeremyevans)
* Have the PostgreSQL and MySQL adapters use the Sequel.time_class setting for datetime/timestamp types (jeremyevans)
* Add Sequel.time_class and String#to_sequel_time, used for converting time values from the database to either Time (default) or DateTime (jeremyevans)
* Make identifier quoting uppercase by default, to work better with the SQL standard, override in PostgreSQL (jeremyevans) (#232)
* Add StringExpression#+, for simple SQL string concatenation (:x.sql_string + :y) (jeremyevans)
* Make to a case sensensitive search on MySQL (use ilike for the old behavior) (jeremyevans)
* Add StringMethods.ilike, for case insensitive pattern matching (jeremyevans)
* Refactor ComplexExpression into three subclasses and a few modules, so operators that don't make sense are not defined for the class (jeremyevans)
=== 2.0.0 (2008-06-01)
* Refactor String inflection support, you must use String.inflections instead of Inflector.inflections now (jeremyevans)
* Allow connection to ODBC-MSSQL via a URL (petersumskas) (#230)
* Comprehensive update of all documentation, except for the block filters and adapters (jeremyevans)
* Handle Date and DateTime value literalization correctly in adapters (jeremyevans)
* Literalize DateTime values the same as Time values (jeremyevans)
* MySQL tinyints are now returned as boolean values instead of integers (jeremyevans)
* Set additional MySQL charset options required for creating tables and databases (tmm1)
* Remove methods deprecated in 1.5.0 (jeremyevans)
* Add Module#metaattr_accessor for creating attr_accessors for the metaclass (jeremyevans)
* Add SQL string concatenation support to blockless filters, via Array#sql_string_join (jeremyevans)
* Add Pagination#last_page? and Pagination#first_page? (apeiros)
* Add limited column reflection support, tested on PostgreSQL, MySQL, and SQLite (jeremyevans)
* Allow the use of :schema__table___table_alias syntax for tables, similar to the column support (jeremyevans)
* Merge metaid gem into core_ext.rb and clean it up, so sequel now has no external dependencies (jeremyevans)
* Add Dataset#as, so using a dataset as a column with an alias is not deprecated (jeremyevans)
* Add Dataset#invert, which returns a dataset with inverted HAVING and WHERE clauses (jeremyevans)
* Add blockless filter syntax support (jeremyevans)
* Passing an array to Dataset#order and Dataset#select no longer works, you need to pass multiple arguments (jeremyevans)
* You should use '?' instead of '(?)' when using interpolated strings with array arguments (jeremyevans)
* Dataset.literal now surrounds the literalization of arrays with parentheses (jeremyevans)
* Add echo option (back?) to sequel command line tool, via -E or --echo (jeremyevans)
* Allow databases to have multiple loggers (jeremyevans)
* The sequel command line tool now also accepts a path to a database config YAML file in addition to a URI (mtodd)
* Major update of the postgresql adapter (jdavis, jeremyevans) (#225)
* Make returning inside of a database transaction commit the transaction (ahoward, jeremyevans)
* Dataset#to_table_reference is now protected, and it has a different API (jeremyevans)
* Dataset#join_table and related functions now take an explicit optional table_alias argument, you can no longer include the table alias in the table argument (jeremyevans)
* Aliased and/or qualified columns with embedded spaces can now be specified as symbols (jeremyevans)
* When identifier quoting is enabled, the SQL standard double quote is used by default (jeremyevans)
* When identifier quoting is enabled, quote tables as well as columns (jeremyevans)
* Make identifier quoting optional, enabled by default (jeremyevans)
* Allow Sequel::Database.connect and related methods to take a block that disconnects the database when the block finishes (jeremyevans)
* Add Dataset#unfiltered, for removing filters from dataset (jeremyevans)
* Add add_foreign_key and add_primary_key methods to the AlterTableGenerator (jeremyevans)
* Allow migration files to have more than 3 digits (jeremyevans)
* Add methods directly to Dataset instead of including modules (jeremyevans)
* Make some Dataset instance methods private: invert_order, insert_default_values_sql (jeremyevans)
* Don't add methods that depend on ParseTree unless you can load ParseTree (jeremyevans)
* Don't wipeout the cached columns every time a dataset is cloned, but only on changes to :select, :sql, :from, or :join (jeremyevans)
* Fix Oracle Adapter (yasushi.abe)
* Fixed sqlite uri so that sqlite:// works just like file:// (2 slashes for a relative path, 3 for an absolute) (dlee)
* Raise a Sequel::Error if an invalid limit or offset is used (jeremyevans)
* Refactor and beef up Dataset#first and Dataset#last, with some change in functionality (jeremyevans)
* Add String#to_datetime, for consistency (jeremyevans)
* Fix Range#interval so that it returns 1 less for an exclusive range
* Change SQLite adapter so it doesn't swallow exceptions other than SQLite3::Exception (such as Interrupt) (jeremyevans)
* Change PostgreSQL and MySQL adapters to raise Sequel::Error instead of database specific errors if a database error occurs (jeremyevans)
* Using a memory database with SQLite now defaults to a single connection, so all queries it uses run against the same database (jeremyevans)
* Fix attempting to query MySQL using the same connection being used to concurrently execute another query (jeremyevans)
* Add options to the connection pool to configure reusing connections and converting exceptions (jeremyevans)
* Use the database driver provided string quoting methods for MySQL and SQLite (jeremyevans) (#223)
* Add ColumnAll#==, for checking the equality of two ColumnAlls (jeremyevans)
* Allow an array of arrays instead of a hash when specifying conditions (jeremyevans)
* Add Sequel::DBI::Database#lowercase, for lowercasing column names (jamesearl)
* Remove Dataset#extend_with_destroy, which may break code that uses Dataset#set_model directly and expects the destroy method to be added (jeremyevans)
* Fix some issues when running on Ruby 1.9 (Zverok, jeremyevans)
* Make the DBI adapter work (partially) with PostgreSQL (Seb)
=== 1.5.1 (2008-04-30)
* Have Dataset#graph give a nil value instead of a hash with all nil values if no matching rows exist in the graphed table (jeremyevans)
=== 1.5.0 (2008-04-29)
* Set a timeout in the Sqlite adapter, default to 5 seconds (hrvoje.marjanovic) (#218)
* Document that calling Sequel::ODBC::Database#execute manually requires you to manually drop the returned object (jeremyevans) (#217)
* Paginating an already paginated/limited dataset now raises an error (jeremyevans)
* Add support for PostgreSQL partial indexes (dlee)
* Added support for arbitrary index types (including spatial indexes) (dlee)
* Quote column names in SQL generated for SQLite (tmm1)
* Deprecate Object#rollback! (jeremyevans)
* Make some Dataset methods private (qualified_column_name, column_list, table_ref, source_list) (jeremyevans)
* Deprecate Dataset methods #set_options, #set_row_proc, #remove_row_proc, and #clone_merge (jeremyevans)
* Add Symbol#*, a replacement for Symbol#all (jeremyevans)
* Deprecate including ColumnMethods in Object, include it in Symbol, String, and Sequel::SQL::Expression (jeremyevans)
* Deprecate Symbol#method_missing, and #AS, #DESC, #ASC, #ALL, and #all from ColumnMethods (jeremyevans)
* Fix table joining in MySQL (jeremyevans)
* Deprecate Sequel.method_missing and Object#Sequel, add real Sequel.adapter methods (jeremyevans)
* Move dataset methods applicable only to paginated datasets into Sequel::Dataset::Pagination (jeremyevans)
* Make Sequel::Dataset::Sequelizer methods private (jeremyevans)
* Deprecate Dataset#method_missing, add real mutation methods (e.g. filter!) (jeremyevans)
* Fix connecting to an MSSQL server via ODBC using domain user credentials (jeremyevans) (#216)
* No longer depend on the assistance gem, merge in the ConnectionPool and .blank methods (jeremyevans)
* No longer depend on ParseTree, RubyInline, or ruby2ruby, but you still need them if you want to use the block filters (jeremyevans)
* Fix JDBC adapter by issuing index things start at 1 (pdamer)
* Fix connecting to a database via the ADO adapter (now requires options instead of URI) (timuckun, jeremyevans) (#204)
* Support storing microseconds in postgres timestamp fields ( (#215)
* Allow joining of multiple datasets, by making the table alias different for each dataset joined (jeremyevans)
* SECURITY: Fix backslash escaping of strings (dlee)
* Add ability to create a graph of objects from a query, with the result split into corresponding tables (jeremyevans) (#113)
* Add attr_accessor for dataset row_proc (jeremyevans)
* Don't redefine Dataset#each when adding a transform or row_proc (jeremyevans)
* Remove array_keys.rb from sequel_core, it was partially broken (since the arrays came from hashes), and redefined Dataset#each (jeremyevans)
* Fix MySQL default values insert (matt.binary) (#196)
* Fix ODBC adapter improperly escaping date and timestamp values (leo.borisenko) (#165)
* Fix renaming columns on MySQL with type :varchar (jeremyevans) (#206)
* Add Sequel::SQL::Function#==, for comparing SQL Functions (jeremyevans) (#209)
* Update Informix adapter to work with Ruby/Informix 0.7.0 (
* Remove sequel_core's knowledge of Sequel::Model (jeremyevans)
* Use "\n" instead of $/ (since $/ can be redefined in ways we do not want) (jeremyevans)
=== 1.4.0 (2008-04-08)
* Merge 3 mysql patches from the bugtracker (mvyver) (#200, #201, #202).
* Merge 2 postgresql patches from the bugtracker ( (#211, 212).
* Allow overriding of default posgres spec database via ENV['SEQUEL_PG_SPEC_DB'] (jeremyevans).
* Allow using the Sequel::Model as the first argument in a dataset join selection (jeremyevans) (#170).
* Add simple callback mechanism to make model eager loading implementation easier (jeremyevans).
* Added Sequel::Error::InvalidOperation class for invalid operations (#198).
* Implemented MySQL::Database#server_version (#199).
* Added spec configuration for MySQL socket file.
* Fixed transform with array tuples in postgres adapter.
* Changed spec configuration to Database objects instead of URIs in order to support custom options for spec databases.
* Renamed schema files.
* Fixed Dataset#from to work correctly with SQL functions (#193).
=== 1.3 (2008-03-08)
* Added configuration file for running specs (#186).
* Changed Database#drop_index to accept fixed arity (#173).
* Changed column definition sql to put UNSIGNED constraint before unique in order to satisfy MySQL (#171).
* Enhanced MySQL adapter to support load data local infile_, added compress option for mysql connection by default (#172).
* Fixed bug when inserting hashes in array tuples mode.
* Changed SQLite adapter to catch RuntimeError raised when executing a statement and raise an Error::InvalidStatement with the offending SQL and error message (#188).
* Added Error::InvalidStatement class.
* Fixed Dataset#reverse to not raise for unordered dataset (#189).
* Added Dataset#unordered method and changed #order to remove order if nil is specified (#190).
* Fixed reversing order of ASC expression (#164).
* Added support for :null => true option when defining table columns (#192).
* Fixed Symbol#method_missing to accept variable arity (#185).
=== 1.2.1 (2008-02-29)
* Added add_constraint and drop_constraint functionality to Database#alter_table (#182).
* Enhanced Dataset#multi_insert to accept datasets (#179).
* Added MySQL::Database#use method for switching database (#180).
* Enhanced Database.uri_to_options to accept uri strings (#178).
* Added Dataset#columns! method that always makes a roundtrip to the DB (#177).
* Added new Dataset#each_page method that iterates over all pages in the result set (#175).
* Added Dataset#reverse alias to Dataset#reverse_order (#174).
* Fixed Dataset#transform_load and #transform_save to create a trasnformed copy of the supplied hash instead of transforming it in place (#184).
* Implemented MySQL::Dataset#replace (#163).
=== 1.2 (2008-02-15)
* Added support for :varchar[100] like type declarations in #create_table.
* Fixed #rename_column in mysql adapter to support types like varchar(255) (#159).
* Added support for order and limit in DELETE statement in MySQL adapter (#160).
* Added checks to Dataset#multi_insert to prevent work if no values are given (#162).
* Override ruby2ruby implementation of Proc#to_sexp which leaks memory (#161).
* Added log option, help for sequel script (#157).
=== 1.1 (2008-02-15)
* Fixed Dataset#join_table to support joining of datasets (#156).
* Changed Dataset#empty? to use EXISTS condition instead of counting records, for much better performance (#158).
* Implemented insertion of multiple records in a single statement for postgres adapter. This feature is available only in postgres 8.2 and newer.
* Implemented Postgres::Database#server_version.
* Implemented Database#get, short for dataset.get(...).
* Refactored Dataset#multi_insert, added #import alias, added support for calling #multi_insert using array of columns and array of value arrays (thanks David Lee).
* Implemented Dataset#get, a replacement for select(column).first[column].
* Implemented Dataset#grep method, poor man's text search.
=== 1.0.10 (2008-02-13)
* Fixed Datset#group_and_count to work inside a query block (#152).
* Changed datasets with transforms to automatically transform hash filters (#155).
* Changed Marshal stock transform to use Base64 encoding with backward-compatibility to support existing marshaled values (#154).
* Added support for inserting multiple records in a single statement using #multi_insert in MySQL adapter (#153).
* Added support for :slice option (same as :commit_every) in Dataset#multi_insert.
* Changed Dataset#all to accept opts and iteration block.
=== 1.0.9 (2008-02-10)
* Implemented Dataset#inspect and Database#inspect (#151).
* Added full-text searching for odbc_mssql adapter (thanks Joseph Love).
* Added AlterTableGenerator#add_full_text_index method.
* Implemented full_text indexing and searching for PostgreSQL adapter (thanks David Lee).
* Implemented full_text indexing and searching for MySQL adapter (thanks David Lee).
* Fixed Dataset#insert_sql to work with array subscript references (thanks Jim Morris).
=== 1.0.8 (2008-02-08)
* Added support for multiple choices in string matching expressions (#147).
* Renamed Dataset#clone_merge to Dataset#clone, works with or without options for merging (#148).
* Fixed MySQL::Database#<< method to always free the result in order to allow multiple calls in a row (#149). Same also for PostgreSQL adapter.
=== 1.0.7 (2008-02-05)
* Added support for conditional filters (using if else statements) inside block filters (thanks Kee).
=== 1.0.6 (2008-02-05)
* Removed code pollution introduced in revs 814, 817 (really bad patch, IMO).
* Fixed joining datasets using aliased tables (#140).
* Added support additional field types in postgresql adapter (#146).
* Added support for date field types in postgresql adapter (#145).
* Fixed Dataset#count to work correctly for grouped datasets (#144).
* Added Dataset#select_more, Dataset#order_more methods (#129).
=== 1.0.5 (2008-01-25)
* Added support for instantiating models by using the load constructor method.
=== (2008-01-24)
* Fixed bin/sequel to require sequel_model if available.
=== 1.0.4 (2008-01-24)
* Added Dataset#select_all method.
* Changed ODBC::Database to support connection using driver and database name, also added support for untitled columns in ODBC::Dataset (thanks Leonid Borisenko).
* Fixed MySQL adapter to correctly format foreign key definitions (#123).
* Changed MySQL::Dataset to allow HAVING clause on ungrouped datasets, and put HAVING clause before ORDER BY clause (#133).
* Changed Dataset#group_and_count to accept multiple columns (#134).
* Fixed database spec to open YAML file in binary mode (#131).
* Cleaned up gem spec (#132).
* Added Dataset#table_exists? convenience method.
=== 1.0.3 (2008-01-17)
* Added support for UNSIGNED constraint, used in MySQL? (#127).
* Implemented constraint definitions inside Database#create_table.
* Fixed postgres adapter to define PGconn#async_exec as alias to #exec if not defined (for pure-ruby postgres driver).
* Added String#to_date. Updated mysql adapter to use String#to_date for mysql date types (thanks drfreeze).
=== 1.0.2 (2008-01-14)
* Removed ConnectionPool, NumericExtensions. Added dependency on assistance.
=== 1.0.1 (2008-01-12)
* Changed postgres adapter to quote column references using double quotes.
* Applied patch for oracle adapter: fix behavior of limit and offset, transactions, #table_exists?, #tables and additional specs (thanks Liming Lian #122).
* Allow for additional filters on a grouped dataset (#119 and #120)
* Changed mysql adapter to default to localhost if :host option is not specified (#114).
* Refactored Sequelizer to use Proc#to_sexp (method provided by r2r).
* Enhanced Database.connect to accept options with string keys, so it can now accept options loaded from YAML files. Database.connect also automatically converts :username option into :user for compatibility with existing YAML configuration files for AR and DataMapper.
=== (2008-01-03)
* Changed MySQL adapter to support specifying socket option.
* Added support for limiting and paginating datasets with fixed SQL, gotten with DB#fetch (thanks Ruy Diaz).
* Added new Dataset#from_self method that returns a dataset selecting from the original dataset.
=== 1.0 (2008-01-02)
* Removed deprecated adapter stubs.
* Removed Sequel::Model() stub.
* Changed name to sequel_core.
* 100% code coverage.
* Fixed error behavior when sequel_model is not available.
* Fixed error behavior when parse_tree or ruby2ruby are not available.
=== (2008-01-01)
* Fixed String#to_time to raise error correctly for invalid time stamps.
* Improved code coverage - now at 99.2%.
=== (2007-12-31)
* Added a stub for Sequel::Model that auto-loads sequel_model.
* Changed Sequel.method_missing and Database.adapter_class to raise AdapterNotFound if an adapter could not be loaded.
* Fixed behavior of error trap in sequel command line tool.
=== 0.5 (2007-12-30)
* Removed model code into separate sub-project. Rearranged trunk into core, model and model_plugins.
=== 0.4.5 (2007-12-25)
* Added rdoc for new alter_table functionality (#109).
* Fixed update_sql with array sub-item keys (#110).
* Refactored model specs.
* Added Model#update as alias to #set.
* Refactored validations code. Renamed Model.validations? into Model.has_validations?.
* Added initial Model validations (Thanks Lance Carlson)
* Added Database#set_column_default method (thanks Jim Morris.)
* Removed warning on uninitialized @transform value (thanks Jim Morris).
=== (2007-12-20)
* Fixed parsing errors in Ruby 1.9.
* Fixed sync problem in connection_pool_spec.
* Changed String#to_time to raise Error::InvalidValue if Time.parse fails.
* Refactored sequel error classes.
=== (2007-12-19)
* Fixed schema generation code to use field quoting and support adapter-specific literalization of default values (#108).
=== 0.4.4 (2007-12-17)
* Implemented Database#rename_table (#104).
* Fixed drop_index in mysql adapter (#103).
* Added ALTER TABLE specs for postgres, sqlite and mysql adapters. Added custom alter_table behavior for sqlite and mysql adapters (#101, #102).
* Added direct Database API for altering tables.
* Added Database#alter_table method with support for adding, dropping, renaming, modifying columns and adding and droppping indexes.
* Added #unique schema method for defining unique indexes (thanks Dado).
* Implemented unfolding of #each calls inside sequelizer blocks (thanks Jim Morris).
=== 0.4.3 (2007-12-15)
* Fixed Dataset#update to accept strings (#98).
* Fixed Model.[] to raise for boolean argument (#97).
* Added Database#add_index method (thanks coda.hale).
* Added error reporting for filtering on comparison not in a block (thanks Jim Morris).
* Added support for inline index definition (thanks Dado).
* Added Database#create_table! method for forcibly creating a table (thanks Dado).
* Added support for using Dataset#update with block.
* Changed subscript access to use | operator.
* Fixed subscript access in sequelizer.
* Added support for subscript access using Symbol#/ operator.
=== (2007-12-10)
* Improved code coverage.
* Fixed Dataset#count to work properly with datasets with fixed SQL (when using #fetch).
* Added Model.create_with_params method that filters the given parameters accordring to the model's columns (thanks Aman Gupta).
=== (2007-12-09)
* Refactored and fixed Dataset#reverse_order to work with field quoting (thanks Christian).
* Fixed problem with field quoting in insert statements.
* Changed sequelizer code to silently fail on any error when requiring parsetree and ruby2ruby.
* Added Database#create_view, #create_or_replace_view and #drop_view methods. Also implemented Dataset#create_view and #create_or_replace_view convenience methods.
* Keep DRY by re-using Model#[]= from method_missing.
* Added Model.fetch alias for DB.fetch.set_model(Model)
=== 0.4.2 (2007-12-07)
* Implemented Model#save_changes.
* Extended Model#save to accept specific columns to update.
* Implemented experimental JDBC adapter.
* Added adapter skeleton as starting point for new adapters.
* Cleaned-up adapters and moved automatic requiring of 'sequel' to adapter stubs.
=== (2007-12-05)
* Better plugin conventions.
* Added experimental OpenBase adapter.
* Fixed Sequel.<xxx> methods to accept options hash as well as database name. Fixed Sequel.connect to accept options hash as well as URI (Wayne).
=== (2007-12-04)
* Added release rake task (using RubyForge).
* Changed to accept variable arity.
* Implemented plugin loading for model classes.
* Fixed odbc-mssql and odbc adapters (thanks Dusty.)
* Implemented odbc-mssql adapter (thanks Dusty.)
=== (2007-11-27)
* Fixed #first and #last functionality in Informix::Dataset (thanks Gerardo Santana).
=== 0.4.1 (2007-11-25)
* Put adapter files in lib/sequel/adapters. Requiring sequel/<adapter> is now deprecated. Users can now just require 'sequel' and adapters are automagically loaded (#93).
=== 0.4.0 (2007-11-24)
* Reorganized lib directory structure.
* Added support for dbi-xxx URI schemes (#86).
* Fixed problem in Database#uri where setting the password would raise an error (#87).
* Improved Dataset#insert_sql to correctly handle string keys (#92).
* Improved error-handling for worker threads. Errors are saved to an array and are accessible through #errors (#91).
* Dataset#uniq/distinct can now accept a column list for DISTINCT ON clauses.
* Fixed Model.all.
* Fixed literalization of strings with escape sequences in postgres adapter (#90).
* Added support for literalizing BigDecimal values (#89).
* Fixed column qualification for joined datasets (thanks Christian).
* Implemented experimental informix adapter.
=== (2007-11-10)
* Changed Dataset#select_sql to support queries without a FROM clause.
=== 0.3.4 (2007-11-10)
* Fixed MySQL adapter to allow calling stored procedures (thanks Sebastian).
* Changed Dataset#each to always return self.
* Fixed SQL functions without arguments in block filters.
* Implemented super-cool Symbol#cast_as method.
* Fixed error message in command-line tool if failed to load adapter (#85).
* Refactored code relating to column references for better extendibility (#88).
* Tiny fix to Model#run_hooks.
=== 0.3.3 (2007-11-04)
* Revised code to generate SQL statements without trailing semicolons.
* Added Sequel::Worker implementation of a simple worker thread for asynchronous execution.
* Added spec for Oracle adapter.
* Fixed Oracle adapter to format INSERT statements without semicolons (thanks Liming Lian).
* Renamed alias to Array#keys as Array#columns instead of Array#fields.
* Renamed FieldCompositionMethods as ColumnCompositionMethods.
* Implemented Sequel::NumericExtensions to provide stuff like 30.days.ago.
=== 0.3.2 (2007-11-01)
* Added #to_column_name as alias to #to_field_name, #column_title as alias to #field_title.
* Added Dataset#interval method for getting interval between minimum/maximum values for a column.
* Fixed Oracle::Database#execute (#84).
* Added group_and_count as general implementation for count_by_xxx.
* Added count_by magic method.
* Added Dataset#range method for getting the minimum/maximum values for a column.
* Fixed timestamp translation in SQLite adapter (#83).
* Experimental DB2 adapter.
* Added Dataset#set as alias to Dataset#update.
* Removed long deprecated expressions.rb code.
* Better documentation.
* Implemented Dataset magic methods: order_by_xxx, group_by_xxx, filter_by_xxx, all_by_xxx, first_by_xxx, last_by_xxx.
* Changed Model.create and to accept a block.
=== 0.3.1 (2007-10-30)
* Typo fixes (#79).
* Added require 'yaml' to dataset.rb (#78).
* Changed postgres adapter to use the ruby-postgres library's type conversion if available (#76).
* Fixed string literalization in mysql adapter for strings with comment backslashes in them (#75).
* Fixed ParseTree dependency to work with version 2.0.0 and later (#74).
* foreign_key definitions now accept :key option for specifying the remote key (#73).
* Fixed Model#method_missing to not raise error for columns not in the table but for which a value exists (#77).
* New documentation for Model.
* Implemented Oracle adapter based on ruby-oci8 library.
* Implemented Model#pk_hash. Is it really necessary?
* Deprecated Model#pkey. Implemented better Model#pk method.
* Specs and docs for Model.one_to_one, Model.one_to_many macros.
=== (2007-10-20)
* Changed Database#fetch to return a modified dataset.
=== 0.3 (2007-10-20)
* Added stock transforms to Dataset#transform. Refactored Model.serialize.
* Added Database#logger= method for setting the database logger object.
* Fixed Model.[] to act as shortcut to Model.find when a hash is given (#71).
* Added support for old and new decimal types in MySQL adapter, and updated MYSQL_TYPES with MySQL 5.0 constants (#72).
* Implemented Database#disconnect method for all adapters.
* Fixed small bug in ArrayKeys module.
* Implemented model caching by primary key.
* Separated Model.find and Model.[] functionality. Model.find takes a filter. Model.[] is strictly for finding by primary keys.
* Enhanced Dataset#first to accept a filter block. Model#find can also now accept a filter block.
* Changed Database#[] to act as shortcut to #fetch if a string is given.
* Renamed Database#each to #fetch. If no block is given, the method returns an enumerator.
* Changed Dataset#join methods to correctly literalize values in join conditions (#70).
* Fixed #filter with ranges to correctly literalize field names (#69).
* Implemented Database#each method for quickly retrieving records with arbitrary SQL (thanks Aman Gupta).
* Fixed bug in postgres adapter where a LiteralString would be literalized as a regular String.
* Fixed SQLite insert with subquery (#68).
* Reverted back to hashes as default mode. Added Sequel.use_array_tuples and Sequel.use_hash_tuples methods.
* Fixed problem with arrays with keys when using #delete.
* Implemented ArrayKeys as substitute for ArrayFields.
* Added Dataset#each_hash method.
* Rewrote SQLite::Database#transaction to use sqlite3-ruby library implementation of transactions.
* Fixed Model.destroy_all to work correctly in cases where no before_destroy hook is defined and an after_destroy hook is defined.
* Restored Model.has_hooks? implementation.
* Changed Database#<< to strip comments and whitespace only when an array is given.
* Changed Schema::Generator#primary_key to accept calls with the type argument omitted.
* Hooks can now be prepended or appended by choice.
* Changed Model.subset to define filter method on the underlying dataset instead of the model class.
* Fixed Dataset#transform to work with array fields.
* Added Dataset#to_csv method.
* PrettyTable can now extract column names from arrayfields.
* Converted ado, dbi, odbc adapters to use arrayfields instead of hashes.
* Fixed composite key support.
* Fixed Dataset#insert_sql, update_sql to support array fields.
* Converted sqlite, mysql, postgres adapters to use arrayfields instead of hashes.
* Extended Dataset#from to auto alias sub-queries.
* Extended Dataset#from to accept hash for aliasing tables.
* Added before_update, after_update hooks.
=== (2007-10-07)
* Added Date literalization to sqlite adapter (#60).
* Changed Model.serialize to allow calling it after the class is defined (#59).
* Fixed after_create hooks to allow calling save inside the hook (#58).
* Fixed MySQL quoting of sql functions (#57).
* Implemented rollback! global method for cancelling transactions in progress.
* Fixed =~ operator in Sequelizer.
* Fixed ODBC::Dataset#fetch_rows (thanks Dusty).
* Renamed Model.recreate_table to create_table!. recreate_table is deprecated and will issue a warning (#56).
=== 0.2.1 (2007-09-24)
* Added default implementation of Model.primary_key_hash.
* Fixed Sequel::Model() to set dataset for inherited classes.
* Rewrote Model.serialize to use Dataset#transform.
* Implemented Dataset#transform.
* Added gem spec for Windows (without ParseTree dependency).
* Added support for dynamic strings in Sequelizer (#49).
* Query branch merged into trunk.
* Implemented self-changing methods.
* Add support for ternary operator to Sequelizer.
* Fixed sequelizer to evaluate expressions if they don't involve symbols or literal strings.
* Added protection against using #each, #delete, #insert, #update inside query blocks.
* Improved Model#method_missing to deal with invalid attributes.
* Implemented Dataset#query.
* Added Dataset#group_by as alias for Dataset#group.
* Added Dataset#order_by as alias for Dataset#order.
* More model refactoring. Added support for composite keys.
* Added Dataset#empty? method (#46).
* Fixed Symbol#to_field_name to support names with numbers and upper-case characters (#45).
* Added install_no_doc rake task.
* Partial refactoring of model code.
* Refactored dataset-model association and added Dataset#set_row_filter method.
* Added support for case-sensitive regexps to mysql adapter.
* Changed mysql adapter to support encoding option as well.
* Added charset/encoding option to postgres adapter.
* Implemented Model.serialize (thanks Aman Gupta.)
* Changed Model.create to INSERT DEFAULT VALUES instead of (id) VALUES (null) (brings back #41.)
* Fixed to work without arguments.
* Added Model.no_primary_key method to allow models without primary keys.
* Added Model#this method (#42 thanks Duane Johnson).
* Fixed Dataset#insert_sql to use DEFAULT VALUES clause if argument is an empty hash.
* Fixed Model.create to work correctly when no argument is passed (#41).
=== (2007-09-07)
* Dataset#insert can now accept subqueries.
* Changed Migrator.apply to return the version.
* Changed Sequel::Model() to cache intermediate classes so descendant classes can be reopened (#39).
* Added :charset option to MySQL adapter (#40).
* Fixed Dataset#exclude to add parens around NOT expression (#38).
* Fixed use of sub-queries with all comparison operators in block filters (#38).
* Fixed arithmetic expressions in block filters to not be literalized.
* Changed Symbol#method_missing to return LiteralString.
* Changed PrettyTable to right-align numbers.
* Fixed Model.create_table (thanks Duane Johnson.)
=== (2007-09-04)
* Improved support for invoking methods with inline procs inside block filters.
=== 0.2.0 (2007-09-02)
* Fixed Model.drop_table (thanks Duane Johnson.)
* Dataset#each can now return rows for arbitrary SQL by specifying :sql option.
* Added spec for postgres adapter.
* Fixed Model.method_missing to work with new SQL generation.
* Fixed #compare_expr to support regexps.
* Fixed postgres, mysql adapters to support regexps.
* More specs for block filters. Updated README.
* Added support for globals and $X macros in block filters.
* Fixed Sequelizer to not fail if ParseTree or Ruby2Ruby gems are missing.
* Renamed String#expr into String#lit (#expr should be deprecated in future versions).
* Renamed Sequel::ExpressionString into LiteralString.
* Fixed Symbol#[] to return an ExpressionString, so as not to be literalized.
* Renamed Dataset::Expressions to Dataset::Sequelizer.
* Renamed Expressions#format_re_expression to match_expr.
* Renamed Expressions#format_eq_expression to compare_expr.
* Added support for Regexp in MySQL adapter.
* Refactored Regexp expressions into a separate #format_re_expression method.
* Added support for arithmetic in proc filters.
* Added support for nested proc expressions, more specs.
* Added support for SQL function using symbols, e.g. :sum[:x].
* Fixed deadlock bug in ConnectionPool.
* Removed deprecated old expressions.rb.
* Rewrote Proc filter feature using ParseTree.
* Added support for additional functions on columns using Symbol#method_missing.
* Added support for supplying filter block to DB#[] method, to allow stuff like DB[:nodes] {:path =~ /^icex1/}.
=== (2007-08-26)
* Added spec for PrettyTable.
* Added specs for Schema::Generator and Model (#36 thanks technoweenie).
* Fixed Sequel::Model.set_schema (#36 thanks technoweenie.)
* Added support for no options on Schema::Generator#foreign_key (#36 thanks technoweenie.)
* Implemented (restored?) Schema::Generator#primary_key_name (#36 thanks technoweenie.)
* Better spec code coverage.
=== (2007-08-24)
* Changed Dataset#set_model to allow supplying additional arguments to the model's initialize method (#35). Thanks Sunny Hirai.
=== (2007-08-22)
* Changed schema generation code to generate separate statements for CREATE TABLE and each CREATE INDEX (#34).
* Refactored Dataset::SQL#field_name for better support of different field quoting standards by specific adapters.
* Added #current_page_record_count for paginated datasets.
* Removed Database#literal and included Dataset::SQL instead.
* Sequel::Dataset:SQL#field_name can now take a hash (as well as #select and any method that uses #field_name) for aliasing column names. E.g. DB[:test].select(:_qqa => 'Date').sql #=> 'SELECT _qqa AS Date FROM test'.
* Moved SingleThreadedPool to lib/sequel/connection_pool.rb.
* Changed SQLite::Dataset to return affected rows for #delete and #update (#33).
* ADO adapter: Added use of Enumerable for Recordset#Fields, playing it safe and moving to the first row before getting results, and changing the auto_increment constant to work for MSSQL.
=== (2007-08-18)
* New ADO adapter by cdcarter (#31).
* Added automatic column aliasing to #avg, #sum, #min and #max (#30).
* Fixed broken Sequel::DBI::Dataset#fetch_rows (#29 thanks cdcarter.)
=== (2007-08-15)
* Fixed DBI adapter.
=== (2007-08-15)
* Added support for executing batch statements in sqlite adapter.
* Changed #current_page_record_range to return 0..0 for an invalid page.
* Fixed joining of aliased tables.
* Improved Symbol#to_field_name to prevent false positives.
* Implemented Dataset#multi_insert with :commit_every option.
* More docs for Dataset#set_model.
* Implemented automatic creation of convenience methods for each adapter (e.g. Sequel.sqlite etc.)
=== (2007-08-13)
* Refactored schema definition code. Gets rid of famous primary_key problem as well as other issues (e.g. issue #22).
* Added #pagination_record_count, #page_range and #current_page_record_range for paginated datasets.
* Changed MySQL adapter to automatically reconnect (issue #26).
* Changed Sequel() to accept variable arity.
* Added :elements option to column definition, in order to support ENUM and SET types.
=== (2007-08-12)
* Fixed migration docs.
* Removed dependency on PGconn in Schema class.
=== (2007-08-11)
* Added Sequel.dbi convenience method for using DBI connection strings to open DBI databases.
=== (2007-08-10)
* Added support for specifying field size in schema definitions (thanks Florian Aßmann.)
* Added migration code based on work by Florian Aßmann.
* Reintroduced metaid dependency. No need to keep a local copy of it.
=== (2007-07-24)
* Removed metaid dependency. Re-factored requires in lib/sequel.rb.
=== (2007-07-22)
* Improved robustness of MySQL::Dataset#field_name.
* Added Sequel.single_threaded= convenience method.
=== 0.1.9 (2007-07-21)
* Fixed #update_sql and #insert_sql to support field quoting by calling #field_name.
* Implemented automatic data type conversion in mysql adapter.
* Added support for boolean literals in mysql adapter.
* Added support for ORDER and LIMIT clauses in UPDATE statements in mysql adapter.
* Implemented correct field quoting (using back-ticks) in mysql adapter.
* Wrote basic MySQL spec.
* Fixd MySQL::Dataset to return correct data types with symbols as hash keys.
* Removed discunctional MySQL::Database#transaction.
* Added support for single threaded operation.
* Fixed bug in Dataset#format_eq_expression where Range objects would not be literalized correctly.
* Added parens around postgres LIKE expressions using regexps.
=== 0.1.8 (2007-07-10)
* Implemented Dataset#columns for retrieving the columns in the result set.
* Updated Model with changes to how model-associated datasets work.
* Beefed-up specs. Coverage is now at 95.0%.
* Added support for polymorphic datasets.
* The adapter dataset interface was simplified and standardized. Only four methods need be overriden: fetch_rows, update, insert and delete.
* The Dataset class was refactored. The bulk of the dataset code was moved into separate modules.
* Renamed Dataset#hash_column to Dataset#to_hash.
* Added some common pragmas to sqlite adapter.
* Added Postgres::Dataset#analyze for EXPLAIN ANALYZE queries.
* Fixed broken Postgres::Dataset#explain.
=== 0.1.7
* Removed db.synchronize wrapping calls in sqlite adapter.
* Implemented Model.join method to restrict returned columns to the model table (thanks Pedro Gutierrez).
* Implemented Dataset#paginate method.
* Fixed after_destroy hook.
* Improved Dataset#first and #last to accept a filter hash.
* Added Dataset#[]= method.
* Added Sequel() convenience method.
* Fixed Dataset#first to include a LIMIT clause for a single record.
* Small fix to Postgres driver to return a primary_key value for the inserted record if it is specified in the insertion values (thanks Florian Aßmann and Pedro Gutierrez).
* Fixed Symbol#DESC to support qualified notation (thanks Pedro Gutierrez).
=== 0.1.6
* Fixed Model#method_missing to raise for an invalid attribute.
* Fixed PrettyTable to print model objects (thanks snok.)
* Fixed ODBC timestamp conversion to return DateTime rather than Time object (thanks snok.)
* Fixed Model.method_missing (thanks snok.)
* Model.method_missing now creates stubs for calling Model.dataset methods. Methods like Model.each etc are removed.
* Changed default join type to INNER JOIN (thanks snok.)
* Added support for literal expressions, e.g. DB[:items].filter(:col1 => 'col2 - 10'.expr).
* Added Dataset#and.
* SQLite adapter opens a memory DB if no database is specified, e.g. 'sqlite:/'.
* Added Dataset#or, pretty nifty.
=== 0.1.5
* Fixed Dataset#join to support multiple joins. Added #left_outer_join, #right_outer_join, #full_outer_join, #inner_join methods.
=== 0.1.4
* Added String#split_sql.
* Implemented Array#to_sql and String#to_sql. Database#to_sql can now take an array of strings and convert into an SQL string. Comments and excessive white-space are removed.
* Improved Schema generator to support data types as method names:
DB.create_table :test do
integer :abc
text :def
* Implemented ODBC adapter.
=== 0.1.3
* Implemented DBI adapter.
* Refactored database connection code. Now handled through Database#connect.
=== 0.1.2
* The first opened database is automatically assigned to to Model.db.
* Removed SequelConnectionError. Exception class errors are converted to RuntimeError.
* Added support for UNION, INTERSECT and EXCEPT set operations.
* Fixed Dataset#single_record to return nil if no record is found.
* Updated specs to conform to RSpec 1.0.
* Added Model#find_or_create method.
* Fixed MySQL::Dataset#query_single (thanks Dries Harnie.)
* Added Model.subset method. Fixed Model.filter and Model.exclude to accept blocks.
* Added Database#uri method.
* Refactored and removed deprecated code in postgres adapter.
* More documentation for Dataset.
* Added Dataset#size as alias to Dataset#count.
* Changed Database#<< to call execute (instead of being an alias). Thus it will work for descendants as well.
* Fixed to accept variable arity.
* Refactored Model#refresh, Model.create. Removed Model#reload.
* Refactored Model hooks.
* Cleaned up Dataset API.
=== 0.1.0
* Changed Database#create_table to only accept a block. Nobody's gonna use the other way.
* Removed Dataset#[]= method. Too confusing and not really useful.
* Fixed ConnectionPool#hold to wrap exceptions only once.
* Dataset#where_list Renamed Dataset#expression_list.
* Added support for qualified fields in Proc expressions (e.g. filter { == 1}.)
* Added like? and in? Proc expression operators.
* Added require 'date' in dataset.rb. Is this a 1.8.5 thing?
* Refactored Dataset to use literal strings instead of format strings (slight performance improvement and better readability.)
* Added support for literalizing Date objects.
* Refactored literalization of Time objects.
=== 0.0.20
* Refactored Dataset where clause construction to use expressions.
* Implemented Proc expressions (adapted from a great idea by Sam Smoot.)
* Fixed Model#map.
* Documentation for ConnectionPool.
* Specs for Database.
=== 0.0.19
* More specs for Dataset.
* Fixed Dataset#invert_order to work correctly with strings.
* Fixed Model#== to check equality of values.
* Added Model#exclude and Model#order.
* Fixed Dataset#order and Dataset#group to behave correctly when supplied with qualified field name symbols.
* Removed Database#literal. Shouldn't have been there.
* Added SQLite::Dataset#explain. Returns an array of opcode hashes.
* Specs for ConnectionPool.
=== 0.0.18
* Implemented SequelError and SequelConnectionError classes. ConnectionPool#hold now catches any connection errors and reraises them SequelConnectionError.
* Removed duplication in Database#[].
* :from and :select options are now always arrays (patch by Alex Bradbury.)
* Fixed Dataset#exclude to work correctly (patch and specs by Alex Bradbury.)
=== 0.0.17
* Fixed Postgres::Database#tables to return table names as symbols (caused problem when using Database#table_exists?).
* Fixed Dataset#from to have variable arity, like Dataset#select and Dataset#where (patch by Alex Bradbury.)
* Added support for GROUP BY and HAVING clauses (patches by Alex Bradbury.) Refactored Dataset#filter.
* More specs.
* Refactored Dataset#where for better composability.
* Added Dataset#[]= method.
* Added support for DISTINCT and OFFSET clauses (patches by Alex Bradbury.) Dataset#limit now accepts ranges. Added Dataset#uniq and distinct methods.
=== 0.0.16
* More documentation.
* Added support for subqueries in Dataset#literal.
* Added support for Model.all_by_XXX methods through Model.method_missing.
* Added basic SQL logging to Database.
* Added Enumerable#send_each convenience method.
* Changed Dataset#destroy to return the number of deleted records.
=== 0.0.15
* Improved Dataset#insert_sql to allow arrays as well as hashes.
* Database#drop_table now accepts a list of table names.
* Added Model#id to to return the id column.
=== 0.0.14
* Fixed Model's attribute accessors (hopefully for the last time).
* Changed Model.db and Model.db= to allow different databases for different model classes.
* Fixed bug in aggregate methods (max, min, etc) for datasets using record classes.
=== 0.0.13
* Fixed Model#method_missing to do both find, filter and attribute accessors. duh.
* Fixed bug in Dataset#literal when quoting arrays of strings (thanks Douglas Koszerek.)
=== 0.0.12
* Model#save now correctly performs an INSERT for new objects.
* Added Model#reload for reloading an object from the database.
* Added Dataset#naked method for getting a version of a dataset that fetches records as hashes.
* Implemented attribute accessors for column values ala ActiveRecord models.
* Fixed filtering using nil values (e.g. dataset.filter(:parent_id => nil)).
=== 0.0.11
* Renamed Model.schema to Model.set_schema and Model.get_schema to Model.schema.
* Improved Model class to allow descendants of model clases (thanks Pedro Gutierrez.)
* Removed require 'postgres' in schema.rb (thanks Douglas Koszerek.)
=== 0.0.10
* Added some examples.
* Added Dataset#print method for pretty-printing tables.
=== 0.0.9
* Fixed Postgres::Database#tables and #locks methods.
* Added PGconn#last_insert_id method that should support all 7.x and 8.x versions of Postgresql.
* Added Dataset#exists method for EXISTS where clauses.
* Changed behavior of Dataset#literal to regard symbols as field names.
* Refactored and DRY'd Dataset#literal and overrides therof. Added support for subqueries in where clause.
=== 0.0.8
* Fixed Dataset#reverse_order to provide chainability. This method can be called without arguments to invert the current order or with arguments to provide a descending order.
* Fixed literal representation of literals in SQLite adapter (thanks Christian Neukirchen!)
* Refactored insert code in Postgres adapter (in preparation for fetching the last insert id for pre-8.1 versions).
=== 0.0.7
* Fixed bug in Model.schema, duh!
=== 0.0.6
* Added Dataset#sql as alias to Dataset#select_sql.
* Dataset#where and Dataset#exclude can now be used for refining dataset conditions, enabling stuff like posts.where(:title => 'abcdef').exclude(:user_id => 3).
* Implemented Dataset#exclude method.
* Added Sequel::Schema#auto_primary_key method for setting an automatic primary key to be added to every table definition. Changed the schema generator to not define a primary key by default.
* Changed Sequel::Database#table_exists? to rely on the tables method if it is available.
* Implemented SQLite::Database#tables.
=== 0.0.5
* Added Dataset#[] method. Refactored Model#find and Model#[].
* Renamed Pool#conn_maker to Pool#connection_proc.
* Added automatic require 'sequel' to all adapters for convenience.
=== 0.0.4
* Added preliminary MySQL support.
* Code cleanup.
=== 0.0.3
* Add Dataset#sum method.
* Added support for exclusive ranges (thanks Christian Neukirchen.)
* Added sequel console for quick'n'dirty access to databases.
* Fixed small bug in Dataset#qualified_field_name for better join support.
=== 0.0.2
* Added as alias to Sequel.connect.
* Refactored Dataset#where_equal_condition into Dataset#where_condition, allowing arrays and ranges, e.g. posts.filter(:stamp => (3.days.ago)..(, or posts.filter(:category => ['ruby', 'postgres', 'linux']).
* Added Model#[]= method for changing column values and Model#save
method for saving them.
* Added Dataset#destroy for deleting each record individually as support for models. Renamed Model#delete to Model#destroy (and Model#destroy_all) ala ActiveRecord.
* Refactored Dataset#first and Dataset#last code. These methods can now accept the number of records to fetch.
=== 0.0.1
* More documentation for Dataset.
* Renamed Database#query to Database#dataset.
* Added Dataset#insert_multiple for inserting multiple records.
* Added Dataset#<< as shorthand for inserting records.
* Added Database#<< method for executing arbitrary SQL.
* Imported Sequel code.
Jump to Line
Something went wrong with that request. Please try again.