Configuration parameters - Prompt - Select kind - How to set default value?


I am having a configuration parameter of prompt kind, and Select type with values No and Yes. This is basically a verification prompt that appears after clicking Build button. I want value of this Select option should always be defaulted to No. User should explicitly select Yes to proceed with build.

Currently the previous selection (Yes or No) gets defaulted when this verification prompt appears.

I tried following in custom script (in a last step) hoping next time when prompt appears, it should default to No. But,  it is not working - 

echo "##teamcity[setParameter name='myParameter' value='no']"

Any help, like how to default value to No in this case?




Here's an example of one of our builds. It's configured as a configuration parameter and in the spec:

select data_1='YES' data_2='NO' display='normal' label='Select one'

Then set the value of the parameter to NO and it should auto select it.


Dylan Munyard

Thank you for your reply.

I had tried this as a first thing, but it does not work this way. Somehow it shows last selected value only as a default value..

Note - Mine is display='prompt'




I checked it with my build first and it selects the value as expected, but perhaps I have it cached so I'm not sure, sorry.


Hi Kulkarniyogeshs here is a screen shot of my build parameter. I tried Value = YES and Value = No in both cases it defaults the expected value:



@Dylan Munyard, 

I appreciate your help, but this is exactly not working for me. For me, it fails in following scenario- 

1. Trigger a build. Pop up appears. Let's say default value is NO. Select YES. Run the build.

2. Now trigger a build second time. Pop up appears. At this point, my expectation is NO should be defaulted. But YES gets defaulted. Seems like it somehow still remembers previous selection.

I am still wondering how it is working for you. My teamcity version is 2020.1 (build 78475), I don't know if version matters. 


Kulkarniyogeshs I see your point when I run a second build after selecting YES it remembers this value. Looks like this is by design, but I found this feature request about the exact thing:


Hi Kulkarniyogeshs, Dylan,

I just wanted to let you know that this is the current design indeed. The feature request Dylan mentioned is aimed to improve it, so it would be great if you could vote for it and maybe share your use case inside the ticket. This will help us to understand how the feature should be implemented.


Please sign in to leave a comment.