Commit e1704850 authored by Benjamin Eberlei's avatar Benjamin Eberlei

[DBAL-497][DBAL-498] Add test.

parent f3844dc2
Subproject commit 15b04ec520ccded3dc0eba65b12a69ff1931360f Subproject commit d1c7d4334e38cad603a5c863d4c7b91bb04ec6b2
...@@ -216,6 +216,12 @@ class SQLServerPlatformTest extends AbstractPlatformTestCase ...@@ -216,6 +216,12 @@ class SQLServerPlatformTest extends AbstractPlatformTestCase
$this->assertEquals('SELECT * FROM (SELECT *, ROW_NUMBER() OVER (ORDER BY uname DESC, uid ASC) AS doctrine_rownum FROM (SELECT u.id uid, u.name uname) dctrn_result) AS doctrine_tbl WHERE doctrine_rownum BETWEEN 6 AND 15', $sql); $this->assertEquals('SELECT * FROM (SELECT *, ROW_NUMBER() OVER (ORDER BY uname DESC, uid ASC) AS doctrine_rownum FROM (SELECT u.id uid, u.name uname) dctrn_result) AS doctrine_tbl WHERE doctrine_rownum BETWEEN 6 AND 15', $sql);
} }
public function testModifyLimitQueryWithFromColumnNames()
{
$sql = $this->_platform->modifyLimitQuery('SELECT a.fromFoo, fromBar FROM foo', 10);
$this->assertEquals('SELECT * FROM (SELECT a.fromFoo, fromBar, ROW_NUMBER() OVER (ORDER BY (SELECT 0)) AS doctrine_rownum FROM foo) AS doctrine_tbl WHERE doctrine_rownum BETWEEN 1 AND 10', $sql);
}
/** /**
* @group DDC-1360 * @group DDC-1360
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment