1 08/03/81  builtin_functions
 2 
 3 The  following  builtin  functions  are implemented within LINUS.  Set
 4 functions  operate  on the results of a SELECT-FROM-WHERE block, while
 5 scalar  functions  operate on single items.  Refer to the LINUS manual
 6 (Order  No.   AZ49)  for  more complete information.
 7 
 8 
 9 Set functions:
10 avg {select X from ...}
11    average (mean) of all X values selected.
12 count {select X1 X2 ... from ...}
13    counts the number of sets of Xi which have been selected.
14 max {select X from ...}
15    maximum of all X values selected.
16 min {select X from ...}
17    minimum of all X values selected.
18 sum {select X from ...}
19    total of all X values selected.
20 
21 
22 Scalar functions (arithmetic):
23 abs (X)
24    absolute value of X.
25 ceil (X)
26    the smallest integer larger than X.
27 floor (X)
28    the largest integer smaller than X.
29 mod (X, Y)
30    X modulus Y.
31 round (X, Q)
32    the rounding of the value of X.
33 
34 
35 Scalar functions (string):
36 after (S1, S2)
37    that portion of S1 occurring after the leftmost occurrence of S2
38    within S1.
39 before (S1, S2)
40    that portion of S1 occurring before the leftmost occurrenceof S2
41    within S1.
42 concat (S1, S2)
43    the concatenation of S1 and S2.
44 index (S1, S2)
45    the position in S1 of the beginning of the leftmost occurrence of S2
46    within S1.
47 reverse (S)
48    the reverse of S.
49 search (C1, C2)
50    the position in C1 of the leftmost occurrence of any character
51    contained in C2.
52 substr (S, I, J)
53    that portion of S beginning with the Ith position and of length J.
54 verify (C1, C2)
55    the position of the first character of C1 that does not occur in C2.