Losing formulas after refreshing workbook

Copper Contributor

Hello,
I have a workbook that is connected to an external database (sql server). When I type in formulas (nested ifs), after refresh, I loose everything. I have tried changing the options under properties but nothing seems to be working.

 

Thanks

3 Replies
You cannot enter formulas in a column which is returned by the query, only in columns that you manually add to the table. But be aware that sometimes Excel fails to autofill all rows with your formulas after a refresh.
It is better to write those formulas in the query itself rather than using Excel formulas, by adding a custom column in the Query. The formula syntax is different, but at least you'll be sure all rows get the calculated result.

@Jan Karel Pieterse Thanks for your reply. 

I tried that too by creating a new column and adding the formulas there, it worked, but after auto refresh it disappears as well. 

Did you make sure all cells of the column contain the same formula (select all cells in column, edit first formula and press control+Enter to enter in all cells of the column)?