summaryrefslogtreecommitdiffstats
path: root/core/Command/Db
Commit message (Collapse)AuthorAgeFilesLines
* Convert command option defaults to stringsChristoph Wurst2021-06-091-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #27429 from nextcloud/bug/26085/wrong-data-add-order-byChristoph Wurst2021-06-091-5/+2
|\ | | | | Don't pass a column object to addOrderBy
| * Fix #26085Daniel Kesselberg2021-06-081-5/+2
| | | | | | | | | | | | | | | | addOrderBy expects a order expression. For the migration scenario we have column objects. Column objects are not supported by quoteColumnName yet. A column object as order expression is most likely an edgy thing when migration database information. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Update php licensesJohn Molakvoæ (skjnldsv)2021-06-0410-15/+12
|/ | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Revert "add a prefix index to filecache.path"Roeland Jago Douma2021-04-081-7/+0
|
* Cleanup unneeded code around database.xmlMorris Jobke2021-03-242-207/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Bye bye database.xmlJoas Schilling2021-03-241-11/+7
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* add a prefix index to filecache.pathRobin Appelman2021-03-191-0/+7
| | | | | | | | | | | | The reason that `filecache.path` hasn't had an index added is the mysql limitation of ~1kb for indexeded fields, which is to small for the `path`, however mysql supports indexing only the first N bytes of a column instead of the entire column, allowing us to add an index even if the column is to long. Because the index doesn't cover the entire column it can't be used in all situations where a normal index would be used, but it does cover the `path like 'folder/path/%'` queries that are used in various places. Sqlite and Postgresql don't support prefix indexes, but they also don't have the 1kb limit and DBAL handles the differences in index creation. Signed-off-by: Robin Appelman <robin@icewind.nl>
* DB conversion: improve console outputSimon Spannagel2021-03-171-1/+4
| | | | Signed-off-by: Simon Spannagel <simonspa@kth.se>
* Migrate internal classes to the OCP db col typesChristoph Wurst2021-01-122-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Bump doctrine/dbal from 2.12.0 to 3.0.0Christoph Wurst2021-01-0811-48/+52
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update license headersChristoph Wurst2020-12-301-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Make oc_files_trash.auto_id a bigintVincent Petry2020-12-231-0/+1
| | | | | | | Adjusted migration. Added to occ command to update existing tables. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-164-6/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #23044 from nextcloud/migration-10.5Roeland Jago Douma2020-12-101-0/+33
|\ | | | | Handle owncloud migration to latest release
| * Add missing index on oc_cards and rename if it previously existedJulius Härtl2020-12-091-0/+33
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Move columns to bigintJulius Härtl2020-12-081-0/+2
|/ | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Create primary keys on all tables and add a command to create the afterwardsJoas Schilling2020-11-101-0/+181
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update ConvertFilecacheBigInt.phptimm2k2020-10-261-0/+1
|
* Make the migration template typedJoas Schilling2020-10-151-3/+3
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-052-19/+19
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* add size index for filecacheRobin Appelman2020-09-221-0/+7
| | | | | | improves performance of #23004 Signed-off-by: Robin Appelman <robin@icewind.nl>
* Remove @suppress SqlInjectionCheckerMorris Jobke2020-09-161-1/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-243-1/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #21599 from nextcloud/debt/noid/type-to-typesRoeland Jago Douma2020-07-021-2/+3
|\ | | | | Replace TYPE with TYPES
| * Replace TYPE with TYPESDaniel Kesselberg2020-06-301-2/+3
| | | | | | | | | | | | As TYPE::* is deprecated. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Add return value to all commandsJoas Schilling2020-06-2610-11/+16
|/ | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Add index to properties tableMario Danic2020-04-301-0/+14
| | | | Signed-off-by: Mario Danic <mario@lovelyhq.com>
* Update license headers for 19Christoph Wurst2020-04-292-0/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-108-13/+4
| | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use elseif instead of else ifChristoph Wurst2020-04-101-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use exactly one empty line after the namespace declarationChristoph Wurst2020-04-094-4/+0
| | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #19890 from nextcloud/enh/comments-reference-idJoas Schilling2020-04-022-1/+106
|\ | | | | Add optional comments reference_id
| * Add optional column oc_comments.reference_idJoas Schilling2020-03-312-1/+106
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Update the license headers for Nextcloud 19Christoph Wurst2020-03-311-1/+1
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix license headersChristoph Wurst2020-01-131-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Introduce new variable with the default answer to allow option ↵Bernhard Ostertag2019-12-291-7/+7
| | | | | | | | --no-interaction for command occ db:convert-type Variable is set to true for --no-interaction and false otherwise Signed-off-by: Bernhard Ostertag <bernieo.code@gmx.de>
* enable option '--no-interaction' for db:convert-typeBernhard Ostertag2019-12-271-5/+7
| | | | Signed-off-by: Bernhard Ostertag <bernieo.code@gmx.de>
* Update license headers for 18Christoph Wurst2019-12-201-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Convert various columns in oc_mounts to bigintGeorg Ehrke2019-12-091-0/+1
| | | | Signed-off-by: Georg Ehrke <developer@georgehrke.com>
* Update license headersChristoph Wurst2019-12-059-9/+26
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #18098 from nextcloud/fix/migration_import_orderRoeland Jago Douma2019-11-251-1/+1
|\ | | | | Fix the import order of new migrations
| * Fix the import order of new migrationsRoeland Jago Douma2019-11-251-1/+1
| | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Merge pull request #18079 from nextcloud/fixes/phpcsRoeland Jago Douma2019-11-252-4/+3
|\ \ | | | | | | Some php-cs fixes
| * | Some php-cs fixesRoeland Jago Douma2019-11-222-4/+3
| |/ | | | | | | | | | | | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Merge pull request #18027 from str0g/fix/14920/convert_type_booleanRoeland Jago Douma2019-11-251-0/+3
|\ \ | |/ |/| Incorrect integer value: '' for column 'password_invalid' while migra…
| * Incorrect integer value: '' for column 'password_invalid' while migrating ↵Łukasz Buśko2019-11-201-0/+3
| | | | | | | | | | | | from pg to mysql #14920 Signed-off-by: Łukasz Buśko <busko.lukasz@pm.me>
* | Convert more columns to bigintRoeland Jago Douma2019-11-201-0/+4
|/ | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Check and add index on principaluri for schedulingobjects tableThomas Citharel2019-10-081-0/+13
| | | | Signed-off-by: Thomas Citharel <tcit@tcit.fr>
* Add index on calendarid for calendarobject_props tableThomas Citharel2019-10-071-0/+13
| | | | Signed-off-by: Thomas Citharel <tcit@tcit.fr>