# How do I create a reporting parameter drop down menu?

**URL:** <https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631>\
**Category:** Ask OpenMRS\
**Tags:** reporting\
**Created:** [January 19, 2017, 1:06am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631 "2017-01-19T01:06:15Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![craigappl](https://talk.openmrs.org/letter_avatar/craigappl/32/6_22734026db12803ebb3e059622ac3534.png) [@craigappl](https://talk.openmrs.org/u/craigappl)\
**Post date:** [January 19, 2017, 1:06am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/1 "2017-01-19T01:06:16Z")

</div>

**Application Name:** OpenMRS Platform **Version Number:** 1.11.x

**Question:** Hi,

I’m creating a SQL Data Set Definition to query a database where time\_period=:time\_period. The time\_period parameter is set to “Single” “string”. I would like to have a drop down menu showing “Week”, “Month”, “Year” as the options, passing the text value to the SQL query. I can’t figure out the advanced properties to get this to display in a select one drop down.

@mseaton I know you’ve done a lot on reporting. Is this possible through the reporting module’s stock interface?

Thanks, Craig

---

<div class="post-metadata">

**Author:** ![mseaton](https://talk.openmrs.org/user_avatar/talk.openmrs.org/mseaton/32/8088_2.png) [@mseaton](https://talk.openmrs.org/u/mseaton)\
**Post date:** [January 19, 2017, 3:59am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/2 "2017-01-19T03:59:50Z")

</div>

@craigappl, I did a quick check and it doesn’t look like this is currently possible. But it looked like it would be straightforward to implement so I gave it a go here:

> <https://issues.openmrs.org/browse/HTMLWIDGETS-22>

Are you in a position to build the latest snapshot of htmlwidgets and give that a shot?

Let me know how you get on with this.

Thanks, Mike

---

<div class="post-metadata">

**Author:** ![dkayiwa](https://talk.openmrs.org/user_avatar/talk.openmrs.org/dkayiwa/32/179_2.png) [@dkayiwa](https://talk.openmrs.org/u/dkayiwa)\
**Post date:** [January 19, 2017, 6:08am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/3 "2017-01-19T06:08:55Z")

</div>

Thanks @mseaton for doing this immediately! 🙂@craigappl as a token of appreciation to Mike, you could add this to the wiki documentation. 😄

---

<div class="post-metadata">

**Author:** ![craigappl](https://talk.openmrs.org/letter_avatar/craigappl/32/6_22734026db12803ebb3e059622ac3534.png) [@craigappl](https://talk.openmrs.org/u/craigappl)\
**Post date:** [January 20, 2017, 1:44am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/4 "2017-01-20T01:44:04Z")

</div>

Thanks @mseaton for doing this immediately! I built and tested the module. Everything works as stated. @dkayiwa I updated [the documentation](https://wiki.openmrs.org/display/docs/Reporting+Module+Parameters).

Craig

---

<div class="post-metadata">

**Author:** ![dkayiwa](https://talk.openmrs.org/user_avatar/talk.openmrs.org/dkayiwa/32/179_2.png) [@dkayiwa](https://talk.openmrs.org/u/dkayiwa)\
**Post date:** [January 20, 2017, 9:23am UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/5 "2017-01-20T09:23:24Z")

</div>

Thanks @craigappl 😄

---

<div class="post-metadata">

**Author:** ![mseaton](https://talk.openmrs.org/user_avatar/talk.openmrs.org/mseaton/32/8088_2.png) [@mseaton](https://talk.openmrs.org/u/mseaton)\
**Post date:** [January 20, 2017, 5:27pm UTC](https://talk.openmrs.org/t/how-do-i-create-a-reporting-parameter-drop-down-menu/9631/6 "2017-01-20T17:27:18Z")

</div>

Great. FYI, I have just posted version 1.8.0 to the module repository with this feature added.
