Rehman Masood

Forum Replies Created

Viewing 15 replies – 1 through 15 (of 48 total)
  • Author
    Replies
  • in reply to: Windows 10 #84358
    Rehman Masood
    Participant

      I have been using it on Windows 10 for almost a year. So far so good!

      in reply to: Load Balancing via Cloverleaf #83656
      Rehman Masood
      Participant

        The closest I got to something like this was trying to load 180 million results in Epic for a conversion. I had to a trx tclproc and used the digit from the MRN to route it the message to one of the 10 threads I used to send data to Epic. I think something similar would work for you.

        in reply to: Need to replace the | (pipe) in OBX.5 with F #83649
        Rehman Masood
        Participant

          Epic does this on their outbound documentation interface. I solved this by setting up Epic to send the RTF in OBX-5 as base64 encoded (there is a PV that allows this) and then on my way switching it back to RTF, I replaced | as F and so forth. Jim/Charlie, are you right. If the source system can’t send it then see if they can send the data as base64 encoded where it might become a little bit easier for u to handle this.

          in reply to: Looking forward to 2016 #83496
          Rehman Masood
          Participant

            Happy New Year! and thanks to all who contribute to the forum!

            in reply to: REGEXP help with anchors #83506
            Rehman Masood
            Participant

              Try this,

              lsearch -regexp $list “^HI$”

              in reply to: Cloverleaf getting messages over HTTP (Raw) using CAA-WS #82986
              Rehman Masood
              Participant

                Thank you! Just sending you an email now.

                in reply to: Retrieve pdf file off windows server to embed in HL7 #82799
                Rehman Masood
                Participant

                  The way I see it is,

                  Option 1. Each time you get a message, you ftp to the folder, grab the file, encode it and send the message. Depending on the volume of messages, this might not be feasible for you.

                  Option 2. The location where the pdf file is somehow mapped as a link to your unix file system. This will allow you to just locally open the file, encode it and send the message. If the volume is high enough, this just might be the option for you.

                  in reply to: Retrieve pdf file off windows server to embed in HL7 #82797
                  Rehman Masood
                  Participant

                    I think FTP is probably going to be better way to go with this like David mentioned. The other alternative would be to setup the windows share via samba so u can access it as a local folder from Cloverleaf.

                    in reply to: Proc for send out multiple messages. #81591
                    Rehman Masood
                    Participant

                      Here is one I wrote to convert to the CD1/CD2/CD3 stuff (I think its lawson ic527 file) to hl7.

                      Code:


                                     set fileptr [open $localfilepathandname]
                                     set mFS |
                                     set mCS ^
                                     set mRS ~
                                     set mEC \
                                     set mSS &
                                     set msgNumber 0
                                     while { [gets $fileptr line] >= 0 } {
                                         set fieldList [split $line $mFS]
                                         set segName [lindex $fieldList 0]
                                         switch -exact — $segName {
                                             MSH {
                                                 set sequenceNumber [lindex $fieldList 12]
                                             }
                                             MFI {
                                                 set masterFileIdentifier [lindex $fieldList 1]
                                                 set enteredDateTime [lindex $fieldList 3]
                                             }
                                             CD1 {
                                                 set productCategory [lindex $fieldList 7]
                                                 if { $productCategory ne “IMPL” } {
                                                     set itemCategory SUPPLY
                                                 }
                                             }
                                             CD2 {
                                                 set itemInfo [lindex $fieldList 2]
                                                 set itemId [string trimleft [lindex [split $itemInfo $mCS] 0] 0]
                                                 puts “itemId $itemId”
                                                 set itemName [string trim [lindex [split $itemInfo $mCS] 1]]
                                                 set itemIdType SUPID
                                                 set packageUnitOfMeasure [lindex $fieldList 4]
                                                 set packageQuantity [lindex $fieldList 5]
                                                 set manufacturerInfo [lindex $fieldList 12]
                                                 set manufacturerId [string trim [lindex [split $manufacturerInfo $mCS] 0]]
                                                 set manufacturerName [string trim [lindex [split $manufacturerInfo $mCS] 2]]
                                                 set manufacturerCatalog [string trim [lindex $fieldList 13]]
                                                 set supplierId [string trim [lindex $fieldList 14]]
                                                 set supplierCatalog [string trim [lindex $fieldList 15]]
                                             }
                                             CD3 {
                                                 set itemStatus [lindex $fieldList 30]
                                                 set patientChargeable [lindex $fieldList 19]
                                                 set patientPrice [string trimleft [lindex $fieldList 25] 0]
                                                 set chargeCDM [lindex $fieldList 26]
                                                 set out {}
                                                 incr msgNumber
                                                 set fields [list MSH$mFS$mCS$mRS$mEC$mSS IC527 LAWSON “” “” $dateTime “” [join [list “MFN” “M16″] $mCS] $dateTime $processingId 2.5 “${sequenceNumber}:${msgNumber}”]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list MFI $masterFileIdentifier “” $enteredDateTime]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list MFE “” “” $enteredDateTime]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list ITM [join [list $itemId $itemName $itemIdType] $mCS] $itemStatus SUPPLY $itemCategory “” [join [list $manufacturerId $manufacturerName] $mCS] $manufacturerCatalog “” $patientChargeable $chargeCDM $patientPrice ]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list VND “” $supplierId $supplierCatalog]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list PKG “” $packageUnitOfMeasure “” $packageQuantity]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list IVT 1 BHMC]
                                                 lappend out [join $fields $mFS]
                                                 set fields [list ZBL $patientPrice]
                                                 lappend out [join $fields $mFS]
                                                 set msg [join $out r]
                                                 set mh [msgcreate]
                                                 msgset $mh “$msgr”
                                                 lappend dispList “CONTINUE $mh”
                                             }
                                         }
                                     }
                                     close $fileptr

                      in reply to: CorePoint, any Pro’s or Con’s? #80792
                      Rehman Masood
                      Participant

                        I have some extensive experience with CorePoint. It is a interface engine that can be used by alot more people where as Cloverleaf is somewhat geared towards folks who have a programming head.

                        The worst thing about CorePoint was how it handled the code base. For example, there was a Test server that contains all the latest objects and then everyone on the team had to sync their personal install of CorePoint with so their local code base was current. So lets say that I am working on an interface, I sync up my computer with Test, then take 2 days to build an interface and meanwhile someone on my team has made an update to some other interface. Now when I try to move my change, I will cause a Fork that requires a manual Resolve which is pretty much useless and a waste of time. God forbid if someone made the change to a object that I was working on, we are in some trouble to figure out how to merge our changes.

                        Another awkward thing of CorePoint was that its admin console was good for 10-15 interfaces but if you are running 100+ interface, it is not that fast. Sometimes to see what an interface sent 10 days ago could take 2-3 hours for me to find.

                        Other then that, the use of the tool is fine. It can do everything Cloverleaf can do and you won’t have to write any programming. You have to pretty strong in regular expressions if you are doing some complicated as regular expressions are used quite often.

                        One thing that striked me odd was that they renamed everything in CorePoint. Like, we all know what translation table. Cloverleaf calls it Table, Rhapsody calls is Table, Bridges calls it Table, OpenLink calls it Table. Well, not CorePoint. You create 2 Code Sets and then link them together to create a Correlation; that is your table.  

                        In the end, I would choose Cloverleaf anytime over CorePoint but dont mind working in it. I will try to see if I can find one of the action lists I created and if it doesnt contain anything PHI related, I will post up here so people can see what they look like.

                        in reply to: CRON jobs, TCL, and HCI all intermingling #80967
                        Rehman Masood
                        Participant

                          Here is something that I had written a while back. It probably does a bit more then u want (for example, it ftp’ed a file over to a server and also did some file header stuff) u can just remove that part. The thread that was writing messages to a file was called pcm_a_out. The example below checks to see the status of that thread and if it running, it will stop it, move the file away and turn it back on.

                          Code:


                          ######################################################################
                          # Name:      ftpEpicAdtToPatientCallManager
                          # Purpose:  
                          # UPoC type: tps
                          # Args:      tps keyedlist containing the following keys:
                          #            MODE    run mode (”start”, “run”, “time” or “shutdown”)
                          #            MSGID   message handle
                          #            CONTEXT tps caller context
                          #            ARGS    user-supplied arguments:
                          #                    
                          #
                          # Returns:   tps disposition list:
                          #            
                          #
                          # Notes:    
                          #
                          # History:   MM/DD/YYYY  Programmer  Modification
                          #            ———-  ———-  ————
                          #            09/27/2012  R. Masood   Initial creation

                          package require ftp

                          proc ftpEpicAdtToPatientCallManager { args } {
                             global HciSite HciConnName HciSiteDir
                             keylget args MODE mode                         ;# Fetch mode
                             set ctx “”   ; keylget args CONTEXT ctx        ;# Fetch tps caller context
                             set uargs {} ; keylget args ARGS uargs         ;# Fetch user-supplied args

                             set debug 0  ;                                 ;# Fetch user argument DEBUG and
                             catch {keylget uargs DEBUG debug}              ;# assume uargs is a keyed list

                             set module “ftpEpicAdtToPatientCallManager/$HciConnName/$ctx” ;# Use this before every echo/puts,
                                                                            ;# it describes where the text came from

                             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
                                     
                                     if { $debug } {
                                         puts stdout “$module: Starting in debug mode…”
                                     }
                                 }

                                 run {
                                     # ‘run’ mode always has a MSGID; fetch and process it
                                     
                                     keylget args MSGID mh
                                     lappend dispList “CONTINUE $mh”
                                 }

                                 time {
                                     # Timer-based processing
                                     # N.B.: there may or may not be a MSGID key in args
                                     puts “*** UPLOAD PROCESS STARTED ***”
                                     set ftphostname “ftp.server.com”
                                     set ftpusername “username”
                                     set ftppassword “password”
                                     set now [clock format [clock seconds] -format “%m%d%Y”]
                                     if { [lsearch -exact [ls $HciSiteDir/exec] monitorShmemFile] == -1 } { exit }
                                     if { [catch {set PCMmsiTocEntry [msiTocEntry “pcm_a_out”]}] } {
                                         catch {msiAttach}
                                         set PCMmsiTocEntry [msiTocEntry “pcm_a_out”]
                                         }
                                     set PCMThreadStatus [keylget PCMmsiTocEntry ALIVE]
                                     set oldadtfile “/data/healthvision/cis5.8/integrator/s_his/data/pcm/pcm_a_out.txt”
                                     set tmpadtfile “[file rootname $oldadtfile].${now}.tmp[file extension $oldadtfile]”
                                     if { $PCMThreadStatus } {
                                         puts “… stopping thread (pcm_a_out) …”
                                         catch {exec hcicmd -p “epic_adt_01” -c “pcm_a_out pstop”}
                                         if { [file exist $oldadtfile] } {
                                             puts “… renaming file ($oldadtfile) to a temporary location ($tmpadtfile)”
                                             file rename -force $oldadtfile $tmpadtfile
                                             }
                                         puts “… starting thread (pcm_a_out)”
                                         catch {exec hcicmd -p “epic_adt_01” -c “pcm_a_out pstart”}
                                         } else {
                                         puts “Thread (pcm_a_out) was not running …”
                                         if { [file exist $oldadtfile] } {
                                             puts “… Renaming file ($oldadtfile) to a temporary location ($tmpadtfile)”
                                             file rename -force $oldadtfile $tmpadtfile
                                             }
                                         }
                                     if { [file exist $tmpadtfile] } {
                                         set upladtfile “[file dirname $oldadtfile]/EPIC_ADT_TO_PCM_${now}.dat”
                                         set hdradtfile “[file dirname $oldadtfile]/PCM_Header.dat”
                                         puts “… making a copy of header file ($hdradtfile) so we can append data to it ($upladtfile)”
                                         file copy -force $hdradtfile $upladtfile
                                         puts “… appending data from temporary file ($tmpadtfile) to the file that will be uploaded ($upladtfile)”
                                         set rfileptr [open $tmpadtfile]
                                         set wfileptr [open $upladtfile a]
                                         while { [gets $rfileptr line] >= 0 } {
                                             puts $wfileptr $line
                                             }
                                         close $rfileptr
                                         close $wfileptr
                                         puts “… deleting temporary file ($tmpadtfile)”
                                         file delete -force $tmpadtfile
                                         if {[set conn [ftp::Open $ftphostname $ftpusername $ftppassword]] == -1} {
                                             puts “Could not connect to the ftp server ($ftphostname) … ”
                                             return
                                             }
                                         puts “… uploading upload file ($upladtfile)”
                                         ftp::Put $conn $upladtfile
                                         ftp::Close $conn
                                         set newadtfile “[file dirname $oldadtfile]/EPIC_ADT_TO_PCM_${now}.sent.dat”
                                         puts “… saving upload file with new name ($newadtfile)”
                                         file rename -force $upladtfile $newadtfile
                                         }
                                     puts “*** UPLOAD PROCESS ENDED ***”
                                 }
                                 
                                 shutdown {
                                     # Doing some clean-up work
                                     
                                 }
                                 
                                 default {
                                     error “Unknown mode ‘$mode’ in $module”
                                 }
                             }

                             return $dispList
                          }

                          in reply to: Active Directory with Global Monitor #79372
                          Rehman Masood
                          Participant

                            Andrea Mancini wrote:

                            Rehman,

                            We are getting the same output at our organization, but it’s not allowing us to log in to the IDE using our AD credentials. Notice in your output it says: Query LDAP failed. Does that mean anything?

                            in reply to: Active Directory with Global Monitor #79367
                            Rehman Masood
                            Participant

                              I am not familiar for the more section. For me, it was adding the following elements at both places,

                              – Host Name

                              – Port

                              – Encryption Method = SSL Encryption

                              – Authentication Method = Simple Authentication

                              – Default Domain Name

                              Here is the output I get when I do the test.

                              Opening LDAP server connection…

                              LDAP Host:

                              LDAP Port:

                              LDAP server connection is opened successfully

                              LDAP server authentication…

                              Start bind request for domainuser …

                              Bind request for domainuser succeeded

                              Querying LDAP server…

                              Search Base: DC=domain

                              Search Filter: (&(|(sAMAccountName=user)(sAMAccountName=user@domain))(objectClass=organizationalPerson)(objectClass=person)(objectClass=top)(objectClass=user))

                              Search Attributes: dn,distinguishedName,cn,sAMAccountName,description,memberOf


                              Begin of Query Result



                               End of Query Result  


                              Query LDAP failed

                              Closing LDAP server connection…

                              Closed LDAP server connection successfully

                              in reply to: Active Directory with Global Monitor #79365
                              Rehman Masood
                              Participant

                                I got it working at 2 different places with no major issues. What issues r u guys having?

                                in reply to: Unsupported Trxid #80748
                                Rehman Masood
                                Participant

                                  I would just set a default route at the end and route it back to the thread with hcitpsmsgkill.

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