Re: Removing unwanted data.
- --- In email@example.com, Robin Chapple <robinski@...> wrote:
>5.1 is needed to use this clip. It uses regex but regex is very fast
> I have made a clip with help from this list to remove unwanted data
> from a statistical report which is collected as HTML from a website.
> The data finishes up like this:
> /db/indexlogin.asp 46 3.71 KB 11 2
> The items are:
> The filename;
> Number of visits
> Average size
> I need to keep the filename and the number of visits. I need to
> remove everything after the second space.
with 5.1 and with this expression. It basically replaces everything
after the first space that follows a digit with nothing. The RSAW at
the end means, regex replace all silently in the whole file.
^!Replace "(?<=\d)(?>\x20\d[^\r\n]+)" >> "" RSAW
;end of clip