• Login
Community
  • Login

select a specific portion of text from .Log files

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
5 Posts 3 Posters 823 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A
    Arshavir Ghahramanyan
    last edited by Jul 6, 2019, 3:18 PM

    Hi guys,

    I need help with the following:

    I have Rec files in a directory ~\record\Lekgx\Rec.log (Lekgx - 1 to 2000)
    I have also Befund files in the same directory ~\record\Lekg*\Befund.txt (Lekg 1 to 2000)

    Rec.log looks like this:

    30/05/2008 09:57:23 Administrator Patient data/Patient ID: -
    30/05/2008 09:57:23 Administrator Patient data/Last name: -
    30/05/2008 09:57:23 Administrator Patient data/First name: -
    30/05/2008 09:57:23 Administrator Patient data/Date of birth: -
    30/05/2008 09:57:23 Administrator Patient data/Sex: -
    30/05/2008 09:57:23 Administrator Patient data/Indication: -
    30/05/2008 09:57:23 Administrator Patient data/Date of recording: -
    30/05/2008 09:57:23 Administrator Patient data/Pacemaker: -
    30/05/2008 09:59:49 Administrator Created in ~\record\Lekgx
    30/05/2008 10:00:15 Administrator Close
    09/06/2008 11:31:07 Administrator Open
    09/06/2008 11:32:06 Administrator Close
    17/06/2008 16:29:13 Administrator Open
    17/06/2008 16:30:47 Administrator Close
    29/07/2008 11:51:32 Administrator Open
    more date more time more users more action

    Befund.txt file looks like this:

    date
    text
    signature

    I need to make a nice Excel document with the Legk numbers, highlited patient info an befund texts.

    Please help

    Archie

    E 1 Reply Last reply Jul 6, 2019, 3:48 PM Reply Quote 0
    • E
      Ekopalypse @Arshavir Ghahramanyan
      last edited by Jul 6, 2019, 3:48 PM

      @Arshavir-Ghahramanyan

      … and how exactly is this related to notepad++?

      1 Reply Last reply Reply Quote 3
      • A
        Arshavir Ghahramanyan
        last edited by Jul 6, 2019, 4:04 PM

        I need a regex to keep only the patient demographics in the log files and delete the rest

        1 Reply Last reply Reply Quote 0
        • T
          Terry R
          last edited by Jul 6, 2019, 8:15 PM

          @Arshavir-Ghahramanyan said:

          I need to make a nice Excel document

          First off welcome to the Notepad++ community. Your initial post is very short on what you need, so much so that @Ekopalypse was right to ask what has this to do with Notepad++ (NPP). If he hadn’t I would have.

          We, on the forum, hope that posters would have attempted something, even if it’s just a sentence telling us what they’ve tried. It does not appear that you have attempted anything. Worse, you haven’t even given us an example of how you want your before data to appear after it has been processed by Notepad++.

          But just to show that I’m not completely unsympathetic I can offer up some suggestions. NPP can bookmark lines containing certain characters/text. In 2 runs you could bookmark lines containing “Patient” and “Created in”, then you can invert the bookmarks so ALL other lines are instead bookmarked, then delete those bookmarked lines leaving ONLY the lines you want.

          Terry

          1 Reply Last reply Reply Quote 4
          • A
            Arshavir Ghahramanyan
            last edited by Jul 23, 2019, 8:31 PM

            Hi Terry,

            Thank you very much.

            I am just very far from programming, our IT guru mate is on annual leave and I was stack with it. )) Thank you very much.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            The Community of users of the Notepad++ text editor.
            Powered by NodeBB | Contributors