How to delete a single message from recovery database

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf How to delete a single message from recovery database

  • Creator
    Topic
  • #51715
    Yamil Velez
    Participant

      Hi all

         I am wondering if there is a way to delete a single message from the recovery database.  I know the patient’s account number and his medical record.

      Thanks in advance

      Yamil

    Viewing 7 reply threads
    • Author
      Replies
      • #71409
        James Cobane
        Participant

          Yamil,

          You can delete a single message from the recovery (or error) databases using the MID (message ID):

          hcidbdump -r -m xxxxxxxx -D

          where xxxxxxxx is the message ID (the number you see after the 0.0. in the hcidbdump -r display).

          You’ll need to determine which message though by doing an UltraLong display to look at the contents of the messages.  Once you’ve identified which message, then you can use the above command to delete it by the MID.  You’ll also need to stop the associated thread to clear the message, as the engine may have a copy of the message in memory.

          Hope this helps.

          Jim Cobane

          Henry Ford Health

        • #71410
          Yamil Velez
          Participant

            Hi James

               Is there a way to look at the message ID in ultralong format in the background without using the GUI

            Thanks

            Yamil

          • #71411
            David Barr
            Participant

              If you use hcidbdump -r -L, you will see the messages in ultra-long format.  The message ID will be on a line that says “msgMid :”.

            • #71412
              Yamil Velez
              Participant

                Hi Dave

                   I am wondering if I can perform search functions in the backend using hcidbdump -r -L.  Is there is a way to grab the file as display by command hcidbdump -r -L and putting the output in a file to do a search?

                Thanks

                Yamil

              • #71413
                Michael Lacriola
                Participant

                  Hello:

                  hcidbdump -r -L > error.out

                  Then you can use your favorite viewer to look and search for entries in that file. Things that come to mind are: vi, cat, pg, more. You can FTP the file to another server and use notepad, wordpad, textpad, ipad…

                  I also like to include the -d and add the destination or possible -f and add the source to keep the file very specific to what I’m looking for.

                  You can get real crazy and write a tcl proc or some sort of script over the file and completely automate it if you have the skillset to do that.

                  Hope this helps.

                • #71414
                  Yamil Velez
                  Participant

                    Thank you very much Micheal,  this the answer I was hoping I get.

                    Thank you again

                    Yamil

                  • #71415
                    Scott Folley
                    Participant

                      I would add something to this.  What Michael says is accurate but if you want to avoid locking the recovery database while this command runs (which will cause messages to be unable to be delivered) then you will want to add the -U switch to the command:

                      hcidbdump -r -U someuser -L > recoverydb.txt

                      The username that you use is not terribly important but what this does is keeps it from using the default username that the engine uses.

                    • #71416
                      Yamil Velez
                      Participant

                        Thanks Scott for the addition information

                        Yamil

                    Viewing 7 reply threads
                    • The forum ‘Cloverleaf’ is closed to new topics and replies.