…ion is given that doesn't indicate Access/Jet (Fixes #332)
… classes that use single table inheritance Before, only the model class that loaded the single_table_inheritance plugin had the logic to return instances of subclasses. This copies that logic into subclasses, so that if you load all instances of a subclass, it can return instances of subsubclasses. Thanks to Max Aller on sequel-talk for pointing out this bug.
At least PostgreSQL doesn't allow schemas to be used when creating temporary tables.
…n_of On ruby 1.9, non-numeric ranges (such as date ranges) are treated differently than 1.8 in regards to include?. In 1.8 include? just checked against the beginning and end of the range, now it checks each object in the range to see if it matches. The 1.8 include? behavior is now known as cover?. This is a simple switch to use cover? if available, and fallback to include? if not.
…rectly on H2 and possibly Oracle Before, Sequel had a default order that it used for column definitions. The columns options used UNIQUE, then NULL/NOT NULL, then DEFAULT. However, that is not valid SQL92. In SQL92, DEFAULT always comes before NULL/NOT NULL and UNIQUE (which are constraints). While it may not be strictly necessary, I decided to break up the column_definition_sql method into smaller parts with a configurable order, similar to how dataset queries are built. While MySQL appears to work with the new default order, based on the MySQL documentation, NULL/NOT NULL comes before default, so I decided to change the order on MySQL (maybe older versions of MySQL enforce it?). This passes on SQLite, MySQL, PostgreSQL, MSSQL, and H2. I'd greatly appreciate testing on other databases. Part of the reason for this change is that Oracle also requires that the SQL92 behavior of defaults being specified before constraints.
…wing others down Rubinius seems to require a longer sleep on the connection pool spec in order to work correctly. This makes rubinius sleep 30 times longer in that spec. Hopefully this will reduce the frequency of false positives.
…is not a tty Previously, unless the -m, -C, -d, or -D options was given, bin/sequel always gave an IRB prompt. This changes that behavior so that if any arguments are present, they are interpreted as filenames and are loaded. Also, if $stdin is not a tty, it is read from and evaled. These changes make bin/sequel operate more like a standard *nix program. For recent Linux users, this also means you can have a shebang line such as: #!/usr/bin/sequel postgres://user:pass@host/db to create a self contained script, where you can have ruby code in the script, with the DB constant already set. This is because recent Linux versions (since 2.6.28) support recursion in the #! handling.
Previously, -r files would be loaded before the DB constant was established. Now, it holds the information in the same data structure as the -L option, which enables it to be loaded in the same order. So if you specify -L before -r, the -L dir will be loaded before the -r dir is required, and vice versa.
…are used Previously, the -L option would not be loaded if one of the above options was used.
…methods Before Model.plugin was special, since it was defined directly on the class. Now, it is defined in ClassMethods instead. This will allow plugins to alter the plugin method itself. For example, you could now have a plugin that changes the behavior of future plugins.
…ruby running on *nix Before, the only real way to connect to MSSQL from a C based ruby on *nix was to use the ODBC adapter with unixodbc and freetds. I've heard it's a big pain to set up, and never attempted to do so myself. Fortunately, tiny_tds was released recently and makes it simple. Thanks to metaskills from the tiny_tds project for making changes to tiny_tds to better support Sequel.