# FLUX and Grafana graph - proper syntax / placement of "|\> fill(usePrevious: true)"?

**URL:** <https://community.grafana.com/t/flux-and-grafana-graph-proper-syntax-placement-of-fill-useprevious-true/41937>\
**Category:** Time Series Panel\
**Created:** [January 20, 2021, 9:13pm UTC](https://community.grafana.com/t/flux-and-grafana-graph-proper-syntax-placement-of-fill-useprevious-true/41937 "2021-01-20T21:13:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![quantenabler](https://avatars.discourse-cdn.com/v4/letter/q/f08c70/32.png) [@quantenabler](https://community.grafana.com/u/quantenabler)\
**Post date:** [January 20, 2021, 9:13pm UTC](https://community.grafana.com/t/flux-and-grafana-graph-proper-syntax-placement-of-fill-useprevious-true/41937/1 "2021-01-20T21:13:11Z")

</div>

running influxdata OSS 1.8.2 and grafana 7.2.  
i have measurement that when queried in regular influxdb and grafana with fill(previous) works, as expected.

converting to FLUX (which i need for soooooo many reasons) i get choppy stacked lines because some null points rather that fill(previous) creep in.

sample code snippet regardless of where i insert the fill line it does not appear to be functioning:  
from(bucket: “app/autogen”)  
|\> range(start: v.timeRangeStart, stop: v.timeRangeStop)  
|\> filter(fn: ® =\> r.\_measurement == “M” and r.Ctag == “${C}” and (r.book == “A” or r.book == “C”) and(r.\_field == “relevant”))  
|\> fill(usePrevious: true)  
|\> window(every: 1m)  
|\> last()  
|\> fill(usePrevious: true)  
|\> pivot(rowKey:[“Ctag”], columnKey: [“book”], valueColumn: “\_value”)  
|\> group(columns: [“Ctag”], mode:“by”)  
|\> fill(usePrevious: true)  
|\> map(fn: ® =\> ({  
time: r.\_stop,  
show\_A: r.A,  
show\_C: r.C  
}))
