tpipe questions

#1
TCC 15.01.40 x64 Windows 7 [Version 6.1.7601]
TCC Build 40 Windows 7 Build 7601 Service Pack 1
Registered to Charles S Galloway - 5 System License
I would like to remove duplicates from a file -

TPIPE /input=input.txt /output=output.txt /dup=

For the /DUP I am not clear about the :

Length and IncludeOne verbs or whatever they are called. I would like to remove duplicates based on the length of each line.....

===========================================================

/split=2,

Since I want to split based on number of lines = the the file size to split at, the charachter to split at, splitchatpos, splitcharcount - they would not have valuses so:

/Split=2,,,,%@eval[%@lines[all.all] / 4]

would give me all.all.000 to all.all.003 and they would contain all the lines of all.all.

============================================================

Also be great is tpipe would have a sort filter....
===========================================================

thank you in advance...
 

rconn

Administrator
Staff member
May 14, 2008
10,749
97
#2
I would like to remove duplicates from a file -

TPIPE /input=input.txt /output=output.txt /dup=

For the /DUP I am not clear about the :

Length and IncludeOne verbs or whatever they are called. I would like to remove duplicates based on the length of each line.....
I don't know what you mean by "based on the length of each line". The Length option just specifies the number of characters you want to compare; you cannot compare based solely on the length of the line (at least, not with the /DUP option).
 
Jan 19, 2011
581
10
Norman, OK
#4
Code:
/dup=0,1,0,99999,0
or in English
Code:
/dup=RemoveDups,CaseSensitive,StartAtZeroColumn,Match99999CharactersOnTheLine,DontIncludeLinesOfCount1
You may need to adjust the 99999 depending if you have lines longer than that.
 
#5
I think I am doing the /split operation correctly?

[C:\TCMD\AFT]tpipe /input=all.txt /log=tpipe.log /split=2,,,,,%@eval[( %@lines[all.txt] / 2) + 1]
TPIPE: The parameter is incorrect.
"/split=2,,,,,13280246.5"

[C:\TCMD\AFT]tpipe /input=all.txt /log=tpipe.log /split=2,,,,,%@int[%@eval[( %@lines[all.txt] / 4) + 1]]
TPIPE: The parameter is incorrect.
"/split=2,,,,,6640123"

[C:\TCMD\AFT]tpipe /input=all.txt /log=tpipe.log /split=2,,,,,%@int[%@eval[( %@lines[all.txt] / 4) + 1]],
TPIPE: The parameter is incorrect.
"/split=2,,,,,6640123,"
 
#6
It would seem you can't give empty arguments. This worked:
Code:
tpipe /input=12345.txt /split=2,0,0,0,0,5
And this didn't:
Code:
tpipe /input=12345.txt /split=2,,,,,5
It also seems, at least in many cases, you must supply **meaningful** data for args that aren't used. For example, putting a non-numeric string where a number is expected (even if not used) causes an error.