Custom Field not displayed when using Database Custom Field plugin

I have configured a custom field with the Keppler Database Custom Field plugin. I wanted to try with a simple select so I tried to configure a query which si statically giving back the number 3.

I turned on Debug and I can see the output like this:

2013-05-28 15:53:05,367 http-bio-8080-exec-37 DEBUG cahi 953x2048x4 1gpefkd /secure/EditAction!default.jspa [databasecf.querydb.impl.QueryDatabaseImpl] Results for executing SQL query >>
select effort from psa_time_entry where task = '1819640'<< are >>[{EFFORT=3.0}]<<

As column I declared effort of course. My database user is read only and I just want to show the field as a text. I wouldn't care if it is shown in a combo though.

The issue is that the field is not shown at all. When I use the where is my field option it tells me that the field has no value and therefore it is not displayed.

Any ideas?


4 answers

1 accepted

0 votes
Accepted answer

You can achieve what you are looking for by using the SIL Script Custom Field from our KCF plugin (Kepler Custom Fields - and the sql routine, which is documented here:

Documentation for the SIL script custom field usage is here:

Basically, you should add a SIL script CF with the following script configured:

return sql("your JNDI datasource", "select effort from psa_time_entry where task = '1819640'");

The field will show you the desired value from database on view issue.

Make sure also that you choose the appropriate searcher for your field. In this case I suppose an Exact Number Searcher would be appropriate. For more details on SIL Script CF check the documentation link pointed above.

Hope this helps.

Hi Carsten,

What databasecf and jira version are you using and on what browser?

Are there any other messages in the log that might give a clue of what is causing the problem?

Do you experience this problem on all screens?

You could try performing a reindex and also cleaning the cache of your browser.

Is the field missing also from the list of custom fields shown when clicking on Configure Fields in the edit issue screen?



Hi Alex,

First of all thanks for your quick answer.

I am using JIRA 5.2.4 and databasecf 2.1.12.

In the logfile are only some debug statements, nothing which would point that something would be wrong. And now that you mentioned it, the field is shown on the edit issue dialog, funny... In the Configure Fields option the field is also visible. So it is only not shown when I view the issue.

I am using Firefox, just to look if the problem occurs in different browsers I tried IE8 with the same result. I just reindexed and cleared the cache with no effect.

any ideas?



What configuration do you have for the dbcf field? You should choose type select list and uncheck "Add None option". However, you still need to enter on edit issue and save the value on issue, otherwise it won't be shown on the view issue screen, as it has no value.

Ok, seems as if i had a different understanding of showing the value. You are right, when I edit the value and save it, then it is displayed correctly. But this value is changing in the database and I cannot always edit the issue to view the correct value...

Is there any solution for just displaying values from databases which are corresponding to the issue in JIRA but will never actively set through the issue? JIRA is not notified when the values are changed in the database :-(

regards Carsten

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Feb 07, 2019 in Marketplace Apps

A Timeless Love Story

It started as any story starts, on a normal, rainy day.   Admin meets App, and her name was Klok2, and like any first relationship we were both trying to make it work but neither one knew what...

478 views 8 28
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you