db
db copied to clipboard
Yii Database Library
In `QueryInterface` it seems some functions are missing: ```` public function each() public function batch() ```` In `Query`, these functions return `BatchQueryResult`. Since from an API perspective `BatchQueryResult` is equal...
Docs for `\yii\db\BaseActiveRecord::save()` ``` @return boolean whether the saving succeeded (i.e. no validation errors occurred) ``` As far as I can tell there are three ways that it can return...
If you use count() method to return the number of rows in your table, you will get the number but as string not integer. You can check that yourself, just...
A MySQL `SET` datatype should be mapped to an array. This would make it much easier to use in forms, e.g. in a `checkboxList()`. For now as a developer I...
### What steps will reproduce the problem? ``` $query = ArClass::find(); $query->addSelect('extraField'); $item = $query->one(); ``` ### What is the expected result? `$item` has all default fields + 1 `extraField`,...
`yii\db\Query::one()` returns `false` if there are no results. In a rare break from consistency, `yii\db\ActiveQuery::one()` returns `null` instead. I can’t think of any reason why they would need to return...
*@SamMousa commented on Jul 5, 2018, 3:34 PM UTC:* MariaDB is diverging more and more from MySQL. ### What steps will reproduce the problem? Try to use JSON columns with...
| Q | A | ------------- | --- | Is bugfix? | ❌ | New feature? | ✔️ | Breaks BC? | ❌ To-do list: - [x] Update version php...
* Allows non-unique param names inside `Expression::$params` (they will be replaced with unique names) * Process `Expression` instances inside `Expression::$params` ### Related PRs * https://github.com/yiisoft/db-sqlite/pull/289 * https://github.com/yiisoft/db-mysql/pull/321 * https://github.com/yiisoft/db-pgsql/pull/336 *...
### Related PRs * yiisoft/db-pgsql#340 * yiisoft/db-sqlite#292 * yiisoft/db-oracle#259 * yiisoft/db-mssql#296 * yiisoft/db-mysql#329 | Q | A | ------------- | --- | Is bugfix? | ❌ | New feature? |...