Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

field-calculator: a new function to fill a string of repeated chars #14950

Closed
qgib opened this issue Mar 21, 2012 · 3 comments
Closed

field-calculator: a new function to fill a string of repeated chars #14950

qgib opened this issue Mar 21, 2012 · 3 comments

Comments

@qgib
Copy link
Contributor

qgib commented Mar 21, 2012

Author Name: aperi2007 - (aperi2007 -)
Original Redmine Issue: 5214


Hi,
in the field-calculator to fill a field of the attribute-table,
should be really useful a function like the
"repeat(S text,N integer)"
to produce a new string with N times the string S,
like as exmaple:

repeat("0", 10) ==> "0000000000"

This is really useful to produce a code-block using it with the "length" functin.

as this example:

= repeat("0",10-length($rec)) || field($rec)

this will produce a code-block like this:

0000000001
0000000002
0000000003
0000000004
0000000005
...
0000000009
0000000010
0000000011

@qgib
Copy link
Contributor Author

qgib commented Apr 15, 2012

Author Name: Giovanni Manghi (@gioman)


  • fixed_version_id was configured as Version 2.0.0

@qgib
Copy link
Contributor Author

qgib commented Oct 5, 2012

Author Name: Paolo Cavallini (@pcav)


This should have been fixed. Please reopen if necessary.


  • resolution was changed from to fixed
  • status_id was changed from Open to Closed

@qgib qgib added this to the Version 2.0.0 milestone May 24, 2019
@qgib qgib closed this as completed May 24, 2019
@gazhay
Copy link

gazhay commented Mar 4, 2020

This function doesn't exist in QGIS 3.10 is it a regression or was it removed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants