When I set remaining estimate to 0h (using the UI or the setEstimate function) on a closed issue, the field is updated on the issue screeen (and in the TIMEESTIMATE field on the DB), but when I perform a JQL search using "remainingEstimate !=0" the issue is displayed in the results with a non 0 value.
e.g. Issue with original estimate set to 8h and logged work to 3h. The issue is closed and the remaining estimate is set to 0h. A search with "remainingEstimate !=0" displays the issue in the results with 5h as remaining estimate. Both JQLqueries and calls to the getEstimate API function return 5h.
WORKAROUND: I can get the correct blank value on a structure view (after running structure maintenance), but the value is still wrong in JQL searchs and Issue API.