Skip to content

Releases: ovos/doctrine1

v1.3.4

17 Oct 10:01
Compare
Choose a tag to compare

What's Changed

Full Changelog: v1.3.3...v1.3.4

v1.3.3

04 Oct 09:19
Compare
Choose a tag to compare
  • php 8.0 compatibility fixes #8
  • migrate test runs from travis to github actions #10

v1.3.2

13 Aug 14:24
Compare
Choose a tag to compare
  • fixed Doctrine_Validator_HtmlColor class name to match the filename and fix compatibility with psr-0 autoloading

v1.3.1

16 Nov 22:54
26238c6
Compare
Choose a tag to compare
  • fixed MySQL8 compatibility issue - row_number is now a reserved word

v1.3.0

29 May 07:49
Compare
Choose a tag to compare
  • php 7.3 and mysql 5.7 compatible
  • [BC BREAK] modified doctrine collection & record serialization - store less data in cache, but losing the feature of keeping state of modified data
  • [BC BREAK] [OV1] fixed orderBy handling in relations - for ordering m2m relations by columns in refClass use refOrderBy!
  • replaced array_diff with Doctrine_Lib::arrayDiffSimple
  • fixed DC-651: Doctrine_Record::option('orderBy', ...) of join's right side being applied to refTable in m2m relationship
  • fixed DC-1056: Doctrine is not compatible with PHP 5.4 due to change in serialize() behaviour.
  • fixed DC-815 (link unavailable): Model's default sorting breaks subqueries
  • throw an exception when variable passed to Doctrine_Collection::compareRecords is not an object
  • set max varchar length to 65535 for mysql (mysql supports it since 5.0.3)
  • fix for Doctrine_Relation_Nest - fix non-equal nested relations, which have orderBy by refClass's column defined, in case that records related to current record have relations between them + modified DC-302 test case to accept the change
  • fix handling quoteIdentifier in relations orderBy
  • added --case CLI param (usage: php run.php --case Doctrine_Ticket_1044_TestCase)
  • fixed weird conditions in _buildSqlFromPart
  • check for non-specified 'ASC' order in automatic orderBy to avoid duplicates
  • fixed DC-797 (link unavailable) - Record hydrated as dirty if optional relation is empty doctrine/doctrine1#8 - fix for Doctrine_Record::_isValueModified
  • fix for Doctrine_Record::getMutators()
  • [OV2] refactored link/unlink methods in Doctrine_Record - now they do not load whole relations before linking/unlinking
  • [OV3] toArray should consider custom accessors also for mapped values
  • [OV4] added postRelatedSave hook in Record to be called on save, after all relations are also saved (original postSave method is called before any relation is saved)
  • [OV5] do not set queryComponents by reference to a subquery - what happens in subquery, stays in subquery
  • [OV6] Added Doctrine_Query_Abstract::getDqlWithParams - returns the DQL query that is represented by this query object, with interpolated param values, and modified Doctrine_Connection to use PDO::quote for quoting string whenever possible
  • [OV7] mysql should also use limit subquery in the same format as pgsql
  • [OV8] queryCache modifications:
    • hook it in getSqlQuery method instead of execute method only
    • added rootAlias, sqlParts (without offset or limit), isLimitSubqueryUsed and limitSubquery to cache
    • always prequery the query in getSqlQuery to call dql callbacks before any sql is generated, not only on execute(), so that cache hash is always calculated properly, and that this method always returns actual end-query incl. any modifications from dql callbacks
    • added isQueryCacheEnabled() method
  • [OV9] cache queries without limit and offset (to save less cache records)
    • added Doctrine_Core::ATTR_QUERY_CACHE_NO_OFFSET_LIMIT - set to true to enable the feature
  • [OV10] Params duplicates for subquery should be inserted in correct place in params array - proper fix for DC-962 (Broken logic when doctrine translates limit's into subqueries, with joins.)
  • [OV11] added parent query components for subqueries, to indicate subquery context - changing cache hash
  • [OV12] Doctrine_Table::columnCount was not refreshed if behaviors added in Doctrine_Record::setUp added some columns causing Doctrine_Record::isInProxyState to break
  • [OV13] change the way DQL is generated for array params in WHERE IN clause - keep single "?" and process it only after query cache is saved/restored
  • [OV14] Limit subquery
    • added order by fields to select clause also for mysql, since it needs it since 5.7 (with ONLY_FULL_GROUP_BY enabled by default in sql-mode)
    • add aliases to selected columns to avoid duplicate column error
    • remember added columns to avoid duplicates + little refactor for optimization
    • distinct with join and order by on joined column is not determinate, it must be wrapped with another subquery (and not only in oracle)
    • changed alias - added _wrap_ to avoid conflicts with limit subquery ordered by joined column
    • fix _isOrderedByJoinedColumn for identifier quoting
    • ids returned by the limit subquery are ordered. The order must be kept while filtering duplicates out in mysql - otherwise limit would be executed after ids are reordered by distinct / group by, and that order cannot be determined.
  • [OV15] do not auto-add primary key fields when group by is used (conform with mysql 5.7 default settings - all non-aggregated columns must be also in group by clause)
  • [OV16] fixed parsing of "set" clause in update queries, improved checks for whether table alias should be used
  • [OV17] Query: remember dependences on table aliases for sql parts, remember dependences on join
    • Other: optimizations, refactorings, commenting out unused code
  • [OV19] Doctrine_Import_Builder handling namespaced classes (e.g. for i18n behavior)
  • [OV20] let the Doctrine_Query::parseFunctionExpression be forgivable if a closing bracket is omitted
  • [OV21] trim strings before converting them into a regex pattern Doctrine_Query_Tokenizer::getSplitRegExpFromArray - in order to match all non-word characters instead of spaces only in e.g. " OR " delimiter - it will be then converted to "\WOR\W"
  • [OV23] wrap count query with another query, if "having" is used not only on expressions, but on fields as well, and when there is no "group by" in the query
  • [OV24] fix double-quoting of selected column names when manually selecting from a joined table
  • changed @Internal comment to @comment to remove a strikethrough on a method in *storm IDE
  • various php 7.x compatibility fixes - in the library and tests