rom-sql

SQL support for rom-rb

MIT License

Downloads
1.4M
Stars
217
Committers
55

Bot releases are visible (Hide)

rom-sql -

Published by flash-gordon about 7 years ago

Changed

  • Added compatibility with dry-types 0.11 (flash-gordon)

Compare v1.3.4..v1.3.5

rom-sql -

Published by flash-gordon over 7 years ago

Added

  • Relation#lock, row-level locking using the SELECT FOR UPDATE clause (flash-gordon)

  • get and get_text methods for the PG::JSON type (flash-gordon)

  • Support for converting data type with CAST using the function DSL (flash-gordon)

      users.select { string::cast(id, 'varchar').as(:id_str) }
    
  • Support forEXISTS (v-kolesnikov)

      subquery = tasks.where(tasks[:user_id].qualified => users[:id].qualified)
      users.where { exists(subquery) }
    

Fixed

  • Fixed a regression introduced in v1.3.2 caused by doing way more work processing the default dataset (flash-gordon)

Compare v1.3.2...v1.3.3

rom-sql -

Published by flash-gordon over 7 years ago

Added

  • Support for filtering with a SQL function in the WHERE clause. Be sure you're using it wisely and don't call it on large datasets ;) (flash-gordon)
  • Void type for calling functions without returning value (flash-gordon)
  • Support for PG::Array transformations and queries (flash-gordon)

Fixed

  • A bunch of warnings from Sequel 4.46

Compare v1.3.1...v1.3.2

rom-sql -

Published by flash-gordon over 7 years ago

Changed

  • [internal] Compatibility with dry-core v0.3.0 (flash-gordon)

Compare v1.3.0...v1.3.1

rom-sql -

Published by flash-gordon over 7 years ago

Added

  • New Relation#exist? predicate checks if the relation has at least one tuple (flash-gordon)
  • Support for JSONB transformations and queries using native DSL (flash-gordon)
  • Add ROM::SQL::Attribute#not for negated boolean equality expressions (AMHOL)
  • Add ROM::SQL::Attribute#! for negated attribute's sql expressions (solnic)
  • Inferrer gets limit constraints for string data types and stores them in type's meta (v-kolesnikov)

Fixed

  • Fixed usage of PostgreSQL's commands with a composite relation (flash-gordon)
  • Translation of true/false/nil equality checks to is/is not SQL statements in ROM::SQL::Attribute#is (AMHOL)
  • associates command plugin coerces parent collections to hashes correctly (aarek+solnic)
  • by_pk works correctly even when PK is not projected (solnic)

Changed

  • Global private interface SQL::Gateway.instance has been deprecated. Now if you run migrations
    with ROM you should set up a ROM config in the db:setup task with something similar to

      namespace :db
        task :setup do
          ROM::SQL::RakeSupport.env = ROM::Configuration.new(:sql, ENV['DATABASE_URL'])
        end
      end
    

Compare v1.2.2...v1.3.0

rom-sql -

Published by flash-gordon over 7 years ago

Changed

  • Updated dry-initializer (flash-gordon)

Compare v1.2.1...v1.2.2

rom-sql -

Published by flash-gordon over 7 years ago

Fixed

  • Allow for joining by a RelationProxy instance from rom-repository (davydovanton)

Compare v1.2.0...v1.2.1

rom-sql -

Published by solnic over 7 years ago

Added

  • Support for configuring multiple associations for a command (solnic)
  • Support for passing parent tuple(s) as parent option in Command#with_association (solnic)
  • Support for join using assocation name (flash-gordon)

Compare v1.1.2...v1.2.0