You might be able to make some progress by starting with writing what you have in the variable to a temp file and playing with the resend feature from the IDE which you can view and will look something like this (forgive me if it is slightly wrong since some genuis made it so you can’t copy/paste it anymore like we could in TK, hint for enhancement)
hcicmd -p super_adt -c “ib_super_adt resend ib_pre_tps data 5120 my_temp_file nl”
I also took a look at hcicmd and see it is a perl script that might reveal the method behind the madness if you have the determination to see how it reads a file and resends to a cloverleaf thread.
Since you are writing HL7 messages to a SQL data base perhaps I can assume you have the Cloverleaf ODBC module.
If that is true I believ you could write a stored procedure that the ODBC module for Cloverleaf could call periodically to have the desired messages pulled and sent to cloverleaf.
Of course, I haven’t done it myself but that is what popped into my head in addition to the approach that you have 80% working it sounds like.
I do recall being able to create message handles and populate metadata from scratch that might allow directing message content in a variable to a thread, but never gave it a try or used those commands much past level 2 training, but those thoughts are also surfacing when I start thinkg about what approaches might work.
Maybe this dialog will get others to start having some ideas that might be more tanglibly useful.
I just don’t have enough time or energy because I have to go help my son do his algebra which has me just about exhausted these days.
Russ Ross
RussRoss318@gmail.com