Ignore line that starts with the letter PTN

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rmnrdi
    Enthusiast
    • Dec 2017
    • 33

    Ignore line that starts with the letter PTN

    I want to ignore the entire line that starts with a certain 3 letters.
    Also, all the lines in this particular file type start with 3 letters and are delimited by a single space or multiple spaces.

    There's some lines that look like this:

    PTN MACDONALD OLD
    or like this
    BMI 0.50 0.50
    or like this
    BLM 3 3

    I need to know how to ignore a line that starts with N characters of my choosing regardless of spaces after.
    For example I want to ignore the following lines that start with PTN or DAT or...whatever else I decide.

    PTN MACDONALD OLD
    or
    DAT 12 19 2017

    FYI. I'm pretty clueless on regex.

    Thanks
  • Aaron
    Team Scooter
    • Oct 2007
    • 15941

    #2
    Hello,

    The grammar type you are looking for is Delimited From:
    ^DTN
    to:
    (blank space here)

    with:
    X End of Line (enabled)
    X Regular Expression (enabled).

    You can define the grammar type as part of the File Format, then mark it as Unimportant in the Session Settings, with the tutorial video here:
    https://www.scootersoftware.com/supp..._unimportantv3
    Aaron P Scooter Software

    Comment

    Working...