equal
deleted
inserted
replaced
42 | relpipe-tr-awk \ |
42 | relpipe-tr-awk \ |
43 --relation 'a' --where 'message == "Hello,"' \ |
43 --relation 'a' --where 'message == "Hello,"' \ |
44 --relation '.*' --drop \ |
44 --relation '.*' --drop \ |
45 | relpipe-out-tabular |
45 | relpipe-out-tabular |
46 |
46 |
47 # Guile transformation: |
47 # Scheme transformation: |
48 cat relpipe-in-sql-1.sql \ |
48 cat relpipe-in-sql-1.sql \ |
49 | relpipe-in-sql \ |
49 | relpipe-in-sql \ |
50 | relpipe-tr-guile \ |
50 | relpipe-tr-scheme \ |
51 --relation 'a' --where '(string= $message "Hello,")' \ |
51 --relation 'a' --where '(string= $message "Hello,")' \ |
52 --relation '.*' --drop \ |
52 --relation '.*' --drop \ |
53 | relpipe-out-tabular]]></m:pre> |
53 | relpipe-out-tabular]]></m:pre> |
54 |
54 |
55 <p>and get filtered output:</p> |
55 <p>and get filtered output:</p> |
66 | relpipe-out-tabular]]></m:pre> |
66 | relpipe-out-tabular]]></m:pre> |
67 |
67 |
68 <p> |
68 <p> |
69 Actually, the <code>relpipe-in-sql</code> is just a symbolic link to the <code>relpipe-tr-sql</code> |
69 Actually, the <code>relpipe-in-sql</code> is just a symbolic link to the <code>relpipe-tr-sql</code> |
70 and have the same capabilities (with just bit different default behavior to match general logic of the input filters). |
70 and have the same capabilities (with just bit different default behavior to match general logic of the input filters). |
71 So if we do not need special feautres of Guile, AWK or other transformation tool, it is better to stay with SQL (when we already use the SQL module). |
71 So if we do not need special feautres of Scheme, AWK or other transformation tool, it is better to stay with SQL (when we already use the SQL module). |
72 </p> |
72 </p> |
73 |
73 |
74 <p> |
74 <p> |
75 The difference between <code>relpipe-tr-sql</code> and <code>relpipe-in-sql</code> is that |
75 The difference between <code>relpipe-tr-sql</code> and <code>relpipe-in-sql</code> is that |
76 the SQL input filter reads SQL scripts from the STDIN while the SQL transformation reads relational data from the STDIN. |
76 the SQL input filter reads SQL scripts from the STDIN while the SQL transformation reads relational data from the STDIN. |