AnsweredAssumed Answered

Case Statement Problem

Question asked by mcintyre2 on Aug 24, 2017
Latest reply on Aug 25, 2017 by beverly

This is kind of complicated.  What I am trying to accomplish is the production of operative reports using text snippets that are called by a "Case" statement. 

 

The way it is set up is that I have a layout called "Op_Templant"  The layout is set up as a form letter with multiple merge fields.  The area that is

giving me problems is that the Case statement has about 60+ different statements within it. I have at least 10 operation selection fields.  OP_1, OP_2, OP_3 etc.    When I select a operation for OP_1, let say "Bilateral Breast Augmentation" this name starts the Case Field.  The Case field essential states this, Case( OP_1= "Bilateral Breast Augmentation" ; Global::gOP_txt_BR_aug_bil; OP_1 = "Abdominoplasty"; Global::gOP_txt_Abdomplsty; and repeated for an additional 60+ operations.             This same Case statement is then used in OP_2, OP_3, OP_4, up to OP_10 by substituting OP_1 for the other OP_'s. 

 

The Op_Template have merge fields in the body of the  report that will print out the operative snippet for that particular operation.

 

Example: If Operation 1 or OP_1 was Bilateral Breast Aug Submuscular then the following snippet would go into the Operative Report.

 

 

This is kind of complicated.  What I am trying to accomplish is the production of operative reports using text snippets that are called by a "Case" statement. 

 

The way it is set up is that I have a layout called "Op_Templant"  The layout is set up as a form letter with multiple merge fields.  The area that is

giving me problems is that the Case statement has about 60+ different statements within it. I have at least 10 operation selection fields.  OP_1, OP_2, OP_3 etc.    When I select a operation for OP_1, let say "Bilateral Breast Augmentation" this name starts the Case Field.  The Case field essential states this, Case( OP_1= "Bilateral Breast Augmentation" ; Global::gOP_txt_BR_aug_bil; OP_1 = "Abdominoplasty"; Global::gOP_txt_Abdomplsty; and repeated for an additional 60+ operations.             This same Case statement is then used in OP_2, OP_3, OP_4, up to OP_10 by substituting OP_1 for the other OP_'s. 

 

The Op_Template have merge fields in the body of the  report that will print out the operative snippet for that particular operation.

 

Example: If Operation 1 or OP_1 was Bilateral Breast Aug Submuscular then the following snippet would go into the Operative Report.

 

Breast Augmentation with Submammary Placement: The patient was taken to the operating room and in placed in supine position.  Her bilateral chest wall was prepped and draped in a sterile manner.  An incision was made in the inframammary fold region as defined by preoperative markings.  

Dissection was carried down to the pectoralis muscle.  Dissection in a subglandular fashion to form the pocket cm was performed under each breast.  Hemostasis was performed with the bovie cautery.  This was done in a bilateral fashion. .........

 

(there can be multiple operations in a single operative report.  ie. a Mommy makeover will have at least 4 operations, 1 bilateral breast augmentation, 2 bilateral wise-pattern beast lifts, 3 abdominoplasty, 4 liposuction of lateral abdomen.  So there are 4 different operative snippets related to the operation in the order in which the operation was done.  ) 

 

The Problem

It works well, except there are certain statements in the Case statement which will not be recognized.  I have tested almost all the operative selection for OP_1, OP_2, OP_3, OP4 and so on.  The Bilateral Wise Patten Mastopexy and several other operation do not trigger the portion of the Case statement that calls the operative snippet.  I have looked for space characters, spelling of called fields, the merge item and I can find nothing that would cause the “Bilateral Wise Pattern Mastopexy“ to trigger the appropriate operative snippet.

 

 

This is the Operative Detail Layout without any information:

 

Screen Shot 2017-08-24 at 3.48.37 PM.png

 

This is the Operative Report related to the Operative Detail above ie. no information:

 

Screen Shot 2017-08-24 at 3.48.59 PM.png

 

This is the Edit Layout for the Operative Report Layout with the merge items

The <<BodyText_OP_1_cscript>> is the where the operative snippet will be placed related to what was selected in “Operation 1” in the Operative Detail Layout.  If it was “Bilateral Breast Augmentation Submuscular” then this snippet would be placed in the merge fields:

 

Breast Augmentation with Submammary Placement: The patient was taken to the operating room and in placed in supine position.  Her bilateral chest wall was prepped and draped in a sterile manner.  An incision was made in the inframammary fold region as defined by preoperative markings.  

Dissection was carried down to the pectoralis muscle.  Dissection in a subglandular fashion to form the pocket cm was performed under each breast.  Hemostasis was performed with the bovie cautery.  This was done in a bilateral fashion. .........

 

Screen Shot 2017-08-24 at 3.49.26 PM.png

 

 

 

This is the Operative Detail Layout with the details added

 

Not the List of Operations, i.e. Operation 1, Operation 2, Operation 3, Operation 4.  The second operation is “Wise Pattern Lift: Bilateral Breast”  The operation comes from a Value List.  They do not necessarily end up as the same name on the Operation Report.

 

Screen Shot 2017-08-24 at 3.53.14 PM.png

 

 

 

This is a portion of the Case Statement that includes the “Bilateral Breast Aug Submuscular” and the Wise-Pattern Lift: Bilateral Breast” that calls the global text for each of the operations.

 

Screen Shot 2017-08-24 at 4.38.24 PM.png

 

 

This is the same script that is used on all the separate operations except the “INDEX_OP_  “  has a different number.

 

 

 

This is the Operative Report From the above Operative Detail Layout.

(The upper index with Diagnosis, Surgeon, Anesthesia is not shown only the area where the operation are listed.  They are not important. they work.) 

 

Note the first operation is “Bilateral Breast Aug Submuscular”, the second is “Bilateral Wise Pattern Mastopexy”, the third is “Abdominoplasty” in the OPERATION(S) list.    The Breast Aug is merged, the Abominoplasty is merged, but the Wise-Pattern Lift: Bilateral Breast is not.  (the Liposuctiion: Lateral Abdomen with Tummy Tuck” snippet is only the title an includes no further detail for now.)  If I put the Wise-Pattern Lift in any of the 10 Operations it still will not merge.

 

Screen Shot 2017-08-24 at 3.53.42 PM.png

 

 

My question is why doesn’t the Case statement call the Wise Pattern Mastopexy Script.  It will not pull up when the Wise Pattern Lift in when placed in any of the 10 Operations in the Detail Layout. 

 

Does this happen with long Case Scripts? 

I know it is a lot of information to sift through but any help would be greatly appreciated. 

Thanks,

 

Dr. B

 

PS. there might be other ways to do develop a unique operative report using a single layout but my other efforts by using multiple Operative Reports Layout, each with the complete operations resulted in too may layouts and each patients having all the operations (60 +) with their name on each.

Outcomes