githubjeka
9ae21e5df2
phpDoc of joinWith updated to \yii\db\ActiveQuery
9 years ago
githubjeka
2b6ceb1eb7
phpDoc updated
9 years ago
Alexander Makarov
5cecb09c1b
Fixes #9443 : Added `unsigned()` to `ColumnSchemaBuilder`
9 years ago
Hereward Mills
a4acd048bc
Add @throws tags to PHPDocs.
9 years ago
SilverFire - Dmitry Naumenko
2275156f7e
PHPDoc updated
9 years ago
Carsten Brandt
468886a77b
small refactoring for #9452
9 years ago
Klimov Paul
bea90e1228
Fixed `yii\db\Query::where()` does not add params from directly passed `yii\db\Expression`
9 years ago
SilverFire - Dmitry Naumenko
cd87d67f34
Global DOCS update: ~~~ replaced with ```
9 years ago
Carsten Brandt
ad69b0f8cb
added note about fields that can be used in onCondition
9 years ago
Carsten Brandt
7c7ed48c4c
cleanup docs and duplicate code in query
9 years ago
Alexander Makarov
8765cae71c
Reverted #9656 because of BC break (reverted from commit 4a464afe9b
)
9 years ago
Sam Mousa
4a464afe9b
Fixes #9656 : `yii\db\BaseActiveRecord` refactored in order to getting, setting and unsetring attribute values using the same approach
9 years ago
Alexander Makarov
e4f5b91f74
Fixed #6351 MySQL 5.1 compatibility
9 years ago
Sam Mousa
603a956b8d
Implemented __sleep in yii\db\Connection
...
to support serializing the connection object without exceptions.
- Added test for serializing an open connection.
- Added unserialize test
close #10149
9 years ago
Alexander Makarov
7641d2d83b
Enhanced #9337 as @klimov-paul suggested in e94810551c (commitcomment-14335135)
9 years ago
Alexander Makarov
cddb036cf9
Fixes #9790 : Fixed `yii\db\sqlite\QueryBuilder` to generate proper SQL for UNION
9 years ago
Constantine Chuprik
e94810551c
Fixes #9337 : Added `yii\db\ColumnSchemaBuilder::defaultExpression()` to support DB Expression as default value
9 years ago
Alexander Makarov
95f251edd1
Fixes #10084 : Improved DB docs
9 years ago
Steve Guns
d40435e931
Enhanced #6351 fix by reintroduced older (SQL CREATE) style FK detection for people still running MySQL servers where referential_constraints is not available
9 years ago
Carsten Brandt
decd45201c
allow passing a single Expression object to select() and addSelect()
...
fixes #9883
9 years ago
Alexander Makarov
1b3770fd21
Use === instead of == where possible
9 years ago
Alexander Makarov
f83d233072
Fixed method call case to match definition
9 years ago
Alexander Makarov
5ab4f0f090
Better quotes usage in strings
...
- Use single quote where interpolation isn't necessary
- Use interpolation when it's better than concatenation
9 years ago
A Slatius
a030cd4250
Allow the use of Yii aliases in an SQLite dsn
...
Making it possible to use a SQLite DSN like;
```php
'db' => [
'dsn' => 'sqlite:@app/db/database.sqlite3',
]
```
That way it'll always work out of the box and absolute paths aren't
needed.
close #9869
9 years ago
jeicd
c2f83da8d8
Fix phpdoc
9 years ago
jeicd
0407407b76
fix coding style to follow PSR-2
9 years ago
Vovan-VE
c68b9a486c
Fix: Issue #9814 : event type EVENT_AFTER_INSERT and EVENT_AFTER_UPDATE
...
Events `EVENT_AFTER_INSERT` and `EVENT_AFTER_UPDATE` are documented
as `Event`, but infact they are `AfterSaveEvent`.
9 years ago
John Was
eb6935e4a8
add more conditions when reading mysql information_schema to speed it up
9 years ago
Jan Waś
191185f5e3
Fixes #6351 : Find MySQL FK constraints from `information_schema` tables instead of `SHOW CREATE TABLE` to improve reliability
9 years ago
Carsten Brandt
229a39dec1
Revert "Fixes #9758 : phpdoc correction"
...
This reverts commit 13a2b70a65
.
The docblock is totally valid as it describes the property defined by this getter.
9 years ago
Alexander Makarov
13a2b70a65
Fixes #9758 : phpdoc correction
9 years ago
Carsten Brandt
4e7adc13ea
adjusted docs about Query::from() and subqueries
...
also added a test to verify behavior
close #9720
close #9266
9 years ago
Aleksandr Golovko
a2f70f6484
Update Query doc return type
...
When used ActiveQuery chain call after call any of join type IDE cannot resolve ActiveQuery methods such an asArray
Example:
SomeActiveRecordModel::find()
->select('...') // return ActiveQuery
->leftJoin('...', '...') // return Query
->asArray() // it's become undefined
->column();
9 years ago
Davide Della Casa Venturelli
329fe129fe
Fixed #9454 : changed sqlsrv pdo class selection
9 years ago
AIZAWA, Hina
0f2a77ed36
Fixes #9442 : Fixed `yii\db\Migration::renameTable()` caused fatal error when using SQLite driver
9 years ago
Carsten Brandt
620ec4d132
added missing namespace on Exception in transaction docs
...
fixes #9429
9 years ago
Carsten Brandt
34d5b45b35
proper fix for #8844 , convert array before using it
...
fixes #9415
9 years ago
Nikola Kovacs
316e95b81d
Remove length from SchemaBuilderTrait::text.
...
close #9307
9 years ago
Michael Härtl
b071587e0a
Improve docs for bindParam() $value
9 years ago
Carsten Brandt
abc7dbbf0f
added missing `@since` annotations
9 years ago
Carsten Brandt
41b25e94b0
improved parameter naming and documentation of schemabuilder
...
changes according to #9191
close #9191
9 years ago
Carsten Brandt
681db52ba6
refactored SchemaBuilder
...
- rename class to ColumnSchemaBuilder as this is more appropriate
- changed internal organisation to match how the rest of schema related classes work
- the ColumnSchemaBuilder is now created the same way as QueryBuilder is
- removed static call magic and method annotations, now real methods are called as they are
- the whole code works on objects in a db context now instead of setting database connection in global state
- trait is now used by Migration by default but can be used in other contexts as well
Migration usage is now as follows:
```php
$this->createTable('example_table', [
'id' => $this->primaryKey(),
'name' => $this->string(64)->notNull(),
'type' => $this->integer()->notNull()->defaultValue(10),
'description' => $this->text(),
'rule_name' => $this->string(64),
'data' => $this->text(),
'created_at' => $this->datetime()->notNull(),
'updated_at' => $this->datetime(),
]);
```
9 years ago
Carsten Brandt
1948754d00
phpdoc and slight refactoring of SchemaBuilder
9 years ago
Carsten Brandt
d8bb724ec7
changed method visibility, fixed test break
9 years ago
Carsten Brandt
7150e830d9
do not use reserved php words as function in schemabuilder
...
there is a reason for them to be reserved, we should not add such workarounds to still use them.
close #9283
9 years ago
Carsten Brandt
8cfc89b21c
adjusted pgsql/QueryBuilder batchInsert to match parent implementation
...
this also fixes #8551
9 years ago
Carsten Brandt
6e3da6b329
various phpdoc fixes
9 years ago
Carsten Brandt
a2568d1ec8
updated some comments and `@since` annotations
9 years ago
Carsten Brandt
6d9fe671de
various code style and whitespace adjustments
9 years ago
Alexander Makarov
310f9152e1
Fixes #9268 : Improved display of boolean parameters in logged SQL queries
9 years ago