Patient Clinical Summary Enhancement-GSOC 2018

@sthaiya @mwere Hi all, I am Madushan and I am going to work on the aforementioned project in this year’s GSOC. Project Objectives-

  1. Create patient summary review/feedback which allows providers
  • to confirm the clinical summary is correct
  • to provide recommendation for the changes
  1. For feedback review, it should allow reviewers
  • to accept recommendations and make changes
  • to decline the recommednations with reasons

Currently I am hoping to add the first feature. Any guidance from the community who are experienced in this module is highly appreciated.

@madushan we are happy to work with you on this project.

@madushan @mwere Thank you all for today’s e-meeting.

@madushan we have agreed that between now and Tuesday you continue familiarizing yourself with OpenMRS clinical summaries handling as well as derived concepts. We will proceed on Tuesday at the agreed time.

1 Like

@sthaiya @mwere Thank you for the meeting. I am extremely sorry for the inconvenience caused. It was out of my control. I will make sure this wouldn’t happen again. I will get familiarized with those during the time.

@sthaiya @mwere I am trying to create an html/text based output for my report which uses a sql dataset definition named ‘to_print_obs’.

I added a weight observation(conceptId = 5089) for patient ‘Dileka’. My sql dataset definition brings the following result.

In my groovy script I added the following code to print obs copying from openMRS wiki.

There is no exception seen and no output is printed. Looking foreward for your help to get this fixed. Thanks

Is this reproducible on the demo server?

@dkayiwa yes, I could reproduce given the credentials.

What are the exact steps to reproduce locally?


  1. Add weight obs for a patient

  2. Create a sql dataset definition to bring obs of the patient

  3. Create a customized report.

  4. Add the created sql dataset definition to the report.

  5. add html/text based output to the report.

  6. In the groovy script add the following code.

    obsList = data.weights

         obsList = util.sort(obsList, "obsDatetime desc")
         count = 0
         for (obs in obsList) {
             if (++count > 3) {
             println obs.valueNumeric  + '  (' + util.format(obs.obsDatetime, 'dd/MMM/yyyy') + ')'


Can you reproduce it on and then give me a direct link to check it out?

UserName: admin Password: Admin123

@dkayiwa Thank you very much for the support. I reproduced a report ‘to print obs’. Please check it here

Can you point me to where you specify the column names that you are referencing in your groovy script?

@dkayiwa I have written a sql query to get all columns from a single row from obs table.

Take a second look at the documentation you linked above in regards to column names.

@dkayiwa the document asks the column to be named ‘weight’. But there are multiple columns in the obs table.

Is any of them named so?

@dkayiwa Thanks for the help. I modified the sql query like this.

select obs_id as weights, obs_datetime as obsDatetime, value_numeric as valueNumeric, date_created from obs where obs_id = 7

But it is still the same.

Can you share a demo server link to your groovy script?


Your link gives me a null pointer exception

@dkayiwa I am sorry for the inconvenience caused. @sthaiya helped me to figure out the mistake. Thank you very much for your help.

`SELECT value_numeric as weights FROM obs' 

would solve the issue.