Using Expressions in PS Query
From TekiWiki
This whole wiki has now moved to http://www.springboardsolutions.com/wiki
Go to this page Using Expressions in PS Query
| Line 25: | Line 25: | ||
'''Examples''' | '''Examples''' | ||
| - | + | <pre> | |
| - | + | Substr(A.DESCR,3) - The description without the first three characters | |
| - | + | </pre> | |
===Function: Translate === | ===Function: Translate === | ||
| Line 39: | Line 39: | ||
Show the format of NATIONAL_ID - useful in a group by query: | Show the format of NATIONAL_ID - useful in a group by query: | ||
| - | + | <pre> | |
| - | + | translate(NATIONAL_ID, | |
'0123456789'||'abcdefghijklmnopqrstuvwxyz'||'ABCDEFGHIJKLMNOPQRSTUVWXYZ' | '0123456789'||'abcdefghijklmnopqrstuvwxyz'||'ABCDEFGHIJKLMNOPQRSTUVWXYZ' | ||
,rpad('9',10)||rpad('x',26)||rpad('X',26)) | ,rpad('9',10)||rpad('x',26)||rpad('X',26)) | ||
| - | + | translate(TextField,'-0123456789','-') - Removes digits from text field. | |
| - | + | </pre> | |
==More About Functions== | ==More About Functions== | ||