Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[processing] Field calculator algorithms should not force an upper limit
on string field lengths

Don't hold back the algorithms because of outdated format limitations!

(cherry picked from commit d614ff3)
  • Loading branch information
nyalldawson committed Feb 12, 2019
1 parent 2e116b6 commit 7830cc7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/FieldPyculator.py
Expand Up @@ -74,7 +74,7 @@ def initAlgorithm(self, config=None):
self.addParameter(QgsProcessingParameterEnum(self.FIELD_TYPE,
self.tr('Field type'), options=self.type_names))
self.addParameter(QgsProcessingParameterNumber(self.FIELD_LENGTH,
self.tr('Field length'), minValue=1, maxValue=255,
self.tr('Field length'), minValue=0,
defaultValue=10))
self.addParameter(QgsProcessingParameterNumber(self.FIELD_PRECISION,
self.tr('Field precision'), minValue=0, maxValue=15,
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/FieldsCalculator.py
Expand Up @@ -79,7 +79,7 @@ def initAlgorithm(self, config=None):
self.addParameter(QgsProcessingParameterEnum(self.FIELD_TYPE,
self.tr('Field type'), options=self.type_names))
self.addParameter(QgsProcessingParameterNumber(self.FIELD_LENGTH,
self.tr('Field length'), minValue=1, maxValue=255, defaultValue=10))
self.tr('Field length'), minValue=0, defaultValue=10))
self.addParameter(QgsProcessingParameterNumber(self.FIELD_PRECISION,
self.tr('Field precision'), minValue=0, maxValue=15, defaultValue=3))
self.addParameter(QgsProcessingParameterBoolean(self.NEW_FIELD,
Expand Down

0 comments on commit 7830cc7

Please sign in to comment.