<p dir="auto">Make sure these boxes are checked before submitting your issue - thank you!</p>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the superset logs for python stacktraces and included it here as text if any</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have reproduced the issue with at least the latest released version of superset</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the issue tracker for the same issue and I haven't found one similar</li>
</ul>
<h3 dir="auto">Superset version</h3>
<p dir="auto">0.20.1</p>
<h3 dir="auto">Expected results</h3>
<p dir="auto">Can use % wildcard in custom WHERE clause</p>
<h3 dir="auto">Actual results</h3>
<p dir="auto">% wildcard gets duplicated when included in the custom where clause</p>
<h3 dir="auto">Steps to reproduce</h3>
<ol dir="auto">
<li>Create a slice</li>
<li>Add a custom query to the "custom WHERE clause" section that includes a wildcard</li>
<li>Click "view query"</li>
<li>Observe that the wildcard is duplicated</li>
</ol>
<p dir="auto">Screenshot (observe the where field in the background):<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/1300331/32190499-67d1f65e-bd84-11e7-8fa7-4b1074710ea7.png"><img src="https://user-images.githubusercontent.com/1300331/32190499-67d1f65e-bd84-11e7-8fa7-4b1074710ea7.png" alt="screen shot 2017-10-30 at 3 09 51 pm" style="max-width: 100%;"></a></p>
<p dir="auto">Name change for chart is not reflected on chart view without refresh and After click on ALTERED then we see white screen and error in the console.</p>
<h3 dir="auto">Expected results</h3>
<p dir="auto">New name should be displayed. Altered should show the difference.</p>
<h3 dir="auto">Actual results</h3>
<p dir="auto">Old name is displayed. Unhandled error after click on altered. <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/junlincc/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/junlincc">@junlincc</a></p>
<h4 dir="auto">Screenshots</h4>
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/25153919/100471315-54e17e80-30da-11eb-99e3-731b2da2f792.gif"><img src="https://user-images.githubusercontent.com/25153919/100471315-54e17e80-30da-11eb-99e3-731b2da2f792.gif" alt="ezgif com-gif-maker" data-animated-image="" style="max-width: 100%;"></a></p>
<h4 dir="auto">How to reproduce the bug</h4>
<ol dir="auto">
<li>Go to charts</li>
<li>Click on any chart</li>
<li>edit chart title and save</li>
<li>see that name has not changed</li>
<li>click on altered</li>
<li>see that white screen is dispplayed</li>
</ol>
<h3 dir="auto">Environment</h3>
<p dir="auto">(please complete the following information):</p>
<p dir="auto">built with docker-compose up<br>
master commit <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/apache/superset/commit/f121107bbe1f43b7e4ba8dd8e5185bf1ab1a5e75/hovercard" href="https://github.com/apache/superset/commit/f121107bbe1f43b7e4ba8dd8e5185bf1ab1a5e75"><tt>f121107</tt></a></p>
<h3 dir="auto">Checklist</h3>
<p dir="auto">Make sure to follow these steps before submitting your issue - thank you!</p>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have checked the superset logs for python stacktraces and included it here as text if there are any.</li>
<li>[x ] I have reproduced the issue with at least the latest released version of superset.</li>
<li>[ x] I have checked the issue tracker for the same issue and I haven't found one similar.</li>
</ul>
<h3 dir="auto">Additional context</h3>