Shaun Beckman

Forum Replies Created

Viewing 15 replies – 1 through 15 (of 48 total)
  • Author
    Replies
  • in reply to: Trying to increment MSG ID for an FT1 split #79970
    Shaun Beckman
    Participant

      Attached is a sample xlate that will help get you started, but keep in mind each message will have the same Msg ID.

      in reply to: Iterate Multiple Groups #75943
      Shaun Beckman
      Participant

        Jim,

        Thanks, you are a wealth of knowledge. I’ll double-check the variant tomorrow, but all the information you provided has me on track. For some reason I was thinking I was going to have to create my own counter for each group.

        Thanks again!!!

        Shaun

        in reply to: Filter msg by comparing dates #74450
        Shaun Beckman
        Participant

          Charlie,

          You did give me a copy, and I have it…somewhere.

          Thanks.

          in reply to: Filter msg by comparing dates #74447
          Shaun Beckman
          Participant

            I’ve been clawing my way up this hill which is turning into a mountain. I found in one case where PV1.44 was blank, that it killed the message. The value of $ATS = 1302066000

            Test message is below. The only way I can think of to resolve that issue is if the message is an A08 and PV1.44 is null, then pass the message. Added to that my previous comment of passing all messages that are not A08s.

            I may be overlooking something simple, but hopefully someone out there in Clovertech land can point me in the right direction. Thanks.

            MSH|^~&|REG|RMC||RMC|20110520000430||ADT^A08|2200765|D|2.2|

            EVN|A08|20110520000430|||OO

            PID|||0600644|116599|HSM^TEST3^^^^||19540503|M||W|1234 MAIN STREET^^KANKAKEE^IL^60901^^|KANK|(815)933-1671||EA|M||003101602|632-33-6699|||E2||||||

            PV1||O|SDS|3|||321^OLOFSSON^BRIAN^P^^MD|||SDS||||1J|||321^OLOFSSON^BRIAN^P^^MD|SDS|706|COMMERCIAL|||||||||N|||||||01|||||D|||||||||||||

            PV2|||HSM TESTING||Y|||||

            IN1|1|099|C5856|AFLAC OPEN ACCESS|1444 N FARNSWORTH AVE ^STE 302^AURORA^IL^60505^^|||||||||||HSM^TEST3^|18|19540503|1234 MAIN STREET^^KANKAKEE^IL^60901^^||||||||||||||||||||||||M||

            IN2||632-33-6699|^||||||||||||||||||||||||||||

            IN1|2||123|SELF PAY – E|^^^^^^|||||||||||HSM^TEST3^|18|19540503|^^^^^^||||||||||||||||||||||||M||

            IN2||632-33-6699|^||||||||||||||||||||||||||||

            ZCN|T123456|HS|TN|

            in reply to: Filter msg by comparing dates #74446
            Shaun Beckman
            Participant

              Jeff,

              Thanks, but I have the following code in the proc to pull the message type:

                        set msg_type [lindex [split $msh_seg |] 8]

                        Result:  ADT^A08

              Either way works, although I like your suggestion better. But I’m having trouble with the syntax of how to pass the message if it is not an A08 before it runs through the entire proc.

              Any suggestionshelp is appreciated.

              in reply to: Filter msg by comparing dates #74444
              Shaun Beckman
              Participant

                Thanks to everyone for all of your suggestions. Sorry it took so long to respond, I have it working almost as expected. If PV1.44 (admit date) is older than the timestamp of the message, the message is passed. This appears to work even if PV1.44 is blank. The issue I am currently having is I need to check to see if the messag is an A08 first. If it is not an A08, then pass the message, if it is an A08, then I need to run it against the proc.

                Below is the full proc (which probably could be done in a much simpler form), and any suggestions on how to first check if the message is an A08 would be greatly appreciated.  Thanks again for all of your suggestions.

                proc filter_time { args } {

                   keylget args MODE mode              ;# Fetch mode

                   set dispList {} ;# Nothing to return

                   switch -exact — $mode {

                       start {

                         # Perform special init functions

                 # N.B.: there may or may not be a MSGID key in args

                       }

                       run {

                 # ‘run’ mode always has a MSGID; fetch and process it

                           keylget args MSGID mh

                           set msg [msgget $mh]

                           set segments [split $msg r]

                           

                           set msh_loc [lsearch -regexp $segments “^MSH”]

                           set msh_seg [lindex $segments $msh_loc]

                           set msh_fld7 [lindex [split $msh_seg |] 6]

                           set msg_type [lindex [split $msh_seg |] 8]            

                   set msg_time [csubstr $msh_fld7 0 14]

                 regsub — {(d{8})(.*)} $msg_time {1} msg_time

                 set TS [clock scan $msg_time]

                           set pv1_loc [lsearch -regexp $segments “^PV1”]

                           set pv1_seg [lindex $segments $pv1_loc]

                   set pv1_44 [lindex [split $pv1_seg |] 44]

                   set admit_time [csubstr $pv1_44 0 14]

                 regsub — {(d{8})(.*)} $admit_time {1} admit_time

                   set ATS [clock scan $admit_time]

                   set x [expr {$TS – $ATS}]

                   

                   

                   puts “msg_type: $msg_type”  

                           puts “MSH Time: $msg_time”

                   puts “PV1_44 Time: $admit_time”

                   puts “TS: $TS”

                   puts “ATS: $ATS”

                   puts “x= $x”

                   

                           # If  message type is ADT^A08

                           # and PV1 field-44.1 is blank, pass message

                   # If PV1.44 is not blank, and MSH Timestamp is greater

                   # than admit timestamp pass message

                   

                                 

                           if {[expr {$TS – $ATS} < 0]} {

                            lappend dispList “KILL $mh”

                           } else {

                            lappend dispList “CONTINUE $mh”

                           }

                       }

                       

                       shutdown {

                   # Doing some clean-up work

                }

                default {

                error “Unknown mode ‘$mode’ in filter_time”

                    }

                   }

                   return $dispList

                }

                in reply to: Filter msg by comparing dates #74441
                Shaun Beckman
                Participant

                  Thanks Jeff.

                  I’ll give it a try as soon as I have time. This is my first time working with the clock command and I was not clear on the syntax.

                  I really appreciate everyone’s help!!!

                  in reply to: Filter msg by comparing dates #74439
                  Shaun Beckman
                  Participant

                    Thank you both for the information.

                    Going off of Jeff’s suggestion, we obtain the date values, convert  those values to Julian date, then determine if the admit date is greater than the message date, and if it is, then block the message. I realized the Julian date does not calculate from an epoch, but from January 1st of the given year. That

                    in reply to: Importing table data #74266
                    Shaun Beckman
                    Participant

                      Tom,

                      Take a look at this post by Garry Fisher.

                      https://usspvlclovertch2.infor.com/viewtopic.php?t=308&highlight=table+creator

                      I have used it several times and it works well. I think you’ll have to convert your spreadsheet into a csv before using though.

                      in reply to: Tcl assistance #73247
                      Shaun Beckman
                      Participant

                        Robert,

                        With the information you provided, and a little tweaking on my part, it is working perfectly.

                        Thank you very much for you help!!!

                        in reply to: Tcl assistance #73245
                        Shaun Beckman
                        Participant

                          Robert,

                          It is real close. It works if the search value is found, but if it is not found, it is only copying the last 4 digits, when I need the entire original number without the leading zero.

                          I’ll keep working on it.

                          Thnanks again.

                          in reply to: Tcl assistance #73244
                          Shaun Beckman
                          Participant

                            Thanks Robert.

                            I’ll give this a try.

                            in reply to: Variable question #72798
                            Shaun Beckman
                            Participant

                              This is the way we do it in an xlate copy statement:

                              set indata [lindex $xlateInVals 0]

                              set xlateOutVals

                                ]

                                in reply to: Remove active nulls from an entire HL7 message #72650
                                Shaun Beckman
                                Participant

                                  We fought the same battle, and use the following post proc.

                                  proc remove_activenull { args } {

                                     keylget args MODE mode               ;# Fetch mode

                                     set dispList {}               ;# Nothing to return

                                     switch -exact — $mode {

                                         start {

                                             # Perform special init functions

                                        # N.B.: there may or may not be a MSGID key in args

                                         }

                                         run {

                                        # ‘run’ mode always has a MSGID; fetch and process it  

                                             keylget args MSGID mh

                                             set msg [msgget $mh]

                                             regsub -all {“} $msg {} msg

                                             msgset $mh $msg

                                             lappend dispList “CONTINUE $mh”

                                         }

                                         time {

                                             # Timer-based processing

                                        # N.B.: there may or may not be a MSGID key in args

                                         }

                                         

                                         shutdown {

                                        # Doing some clean-up work

                                    }

                                     }

                                     return $dispList

                                  }

                                  in reply to: Documentation of Interfaces #72286
                                  Shaun Beckman
                                  Participant

                                    I emailed Raymond Bakker asking about information regarding Doctools. Here is his response:

                                    Hereby I would like you thank you for your interest in the Doctools XML.

                                    Last week I have been contacted by a number of people who have shown interest and I understand that this is due to a post on the Clovertech forum.

                                    Although we are pleased by the feedback we have received, we cannot provide you with the software as it was built by E.Novation with sole purpose to provide it to our direct customers and business partners.

                                    Next versions of the Doctools software will have a modified disclaimer where this will be explicitly stated.

                                    If you have any further questions I will be happy to answer them for you.

                                    Thank you.

                                    With kind regards,

                                    Raymond Bakker

                                    Integration Consultant

                                  Viewing 15 replies – 1 through 15 (of 48 total)