Page 1 of 1
Restrict to: Blocks of lines
Posted: Tue May 13, 2008 11:30 pm
by alnico
Hi,
Restrict to: Blocks of lines...
I have just spent hours trying to figure out why this restriction would not work...I am pretty sure it is because there is a limit on the size it can handle.
Therefore, I tested with a replace filter and had to increase the the 'Maximum Match Size' in order for it to match. If this is indeed the problem then I am assuming that exposing the 'Maximum Match Size' for the Restrict to: Blocks of lines filter would fix it?
Just letting you know,
Re: Restrict to: Blocks of lines
Posted: Thu May 15, 2008 1:46 pm
by DataMystic Support
No, there is no restriction on size here, apart from your memory limit.
To test it working on a small number of lines, use a filter like this:
Code: Select all
Restrict to blocks of 10 lines
|
+--Perl pattern [.*?] with [$0]
[ ] Match case
[ ] Whole words only
[ ] Case sensitive replace
[X] Prompt on replace
[ ] Skip prompt if identical
[ ] First only
[ ] Extract matches
Maximum text buffer size 40096
[ ] Maximum match (greedy)
[ ] Allow comments
[X] '.' matches newline
[ ] UTF-8 Support
The restriction doesn't care about the number of lines, but the search/replace does (for efficiency).
What are you trying to do?
Re: Restrict to: Blocks of lines
Posted: Fri May 16, 2008 12:24 am
by alnico
Here is what I am doing:
|--Restrict to blocks of 2 lines
| |
| +--Restrict to each line in turn
| |
| +--Restrict to between tags <table>...</table>
The "Restrict to blocks of 2 lines" fails at two lines that are a total of 17,000 characters in length, so if I...
Replace the "Restrict to blocks of 2 lines" filter with: Perl pattern [^.*\r\n.*\r\n] with [$0] and increase the Maximum text buffer size...it then works.
Thanks,
Re: Restrict to: Blocks of lines
Posted: Fri May 16, 2008 12:03 pm
by DataMystic Support
I'd be willing to bet that it doesn't
I'll bet that you have an inadvertent CR or LF on the line somewhere. Place a Convert EOL filter at the top of your filter list - convert Auto to DOS, and see what happens then.
We'd love to see the sample data if this still doesn't work. The Restrict to lines filter doesn't use a pattern match - it uses a highly efficient state machine with no practical size limit.