Using Expressions in PS Query

From TekiWiki

Jump to: navigation, search

This whole wiki has now moved to http://www.springboardsolutions.com/wiki

Go to this page Using Expressions in PS Query

 
Line 6: Line 6:
===Function: || (Concatenate) ===
===Function: || (Concatenate) ===
'''Usage: 'Putting ' || A.COLUMN || ' and strings together' '''
'''Usage: 'Putting ' || A.COLUMN || ' and strings together' '''
 +
This concatenates (puts together) column values and fixed character values. This has got to be one of the most useful functions.
This concatenates (puts together) column values and fixed character values. This has got to be one of the most useful functions.
'''Examples'''
'''Examples'''
<pre>
<pre>
-
'PS_' || A.RECNAME
+
'PS_' || A.RECNAME /* Gives the standard table name from the record name. */
</pre>
</pre>
-
Gives the standard table name from the record name.
+
 
Line 26: Line 27:
'''Examples'''
'''Examples'''
<pre>
<pre>
-
Substr(A.DESCR,3) - The description without the first three characters
+
Substr(A.DESCR,3) /* The description without the first three characters */
</pre>
</pre>
Line 41: Line 42:
<pre>
<pre>
translate(NATIONAL_ID,
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)) /* Format of NATIONAL_ID */
-
translate(TextField,'-0123456789','-') - Removes digits from text field.
+
translate(DESCR,'-0123456789','-') /* Removes digits from descriptiont field. */
</pre>
</pre>
==More About Functions==
==More About Functions==
-
For more information about functions in [[PeopleSoft Query]], get a copy of our eBook:
+
{| class="wikitable"
 +
|-
 +
|[[File:UsingFunctionsInPeopleSoftQuerySmall.jpg|90px|link=http://www.amazon.co.uk/gp/product/B013ZRND0I/ref=as_li_tl?ie=UTF8&camp=1634&creative=6738&creativeASIN=B013ZRND0I&linkCode=as2&tag=springboardso-21]]
 +
 
 +
|For more information about functions in [[PeopleSoft Query]] and some other interesting stuff too, read our eBook:
[http://www.amazon.co.uk/gp/product/B013ZRND0I/ref=as_li_tl?ie=UTF8&camp=1634&creative=6738&creativeASIN=B013ZRND0I&linkCode=as2&tag=springboardso-21 Using Functions in PeopleSoft Query]
[http://www.amazon.co.uk/gp/product/B013ZRND0I/ref=as_li_tl?ie=UTF8&camp=1634&creative=6738&creativeASIN=B013ZRND0I&linkCode=as2&tag=springboardso-21 Using Functions in PeopleSoft Query]
 +
 +
|}

Latest revision as of 06:39, 4 January 2016

Personal tools