fixed line chart and edit sql for column chart