Excel query with connection to MS Access

SHARPY1

Board Regular
Joined
Oct 1, 2007
Messages
179
Hi,
I have a spreadsheet with columns A-D pulling data from a MS Access query,
the rest of the spreadsheet has formulas all the way across to column GP.

When i refresh the query it updates columns A-D perfectly, however it messes up my formulas in the other columns,
not sure why it does this? really don't want it to.

To give you an idea of the type of formulas this is one in column K row 468
{=IF(COUNTIF($A$4:$A467,$A468)<3,"",AVERAGE(IF($A$4:$A467=$A468,IF(ROW($A$4:$A467)>=LARGE(IF($A$4:$A467=$A468,ROW($A$4:$A467)),3),$G$4:$G467))))}

as an example if data in columns A-D is currently down to row 468 and all formula's are correct.
If i then refresh data and it is extended to row 473 formulas are messed up
example cell K469 shows formula {=IF(COUNTIF($A$4:$A473,$A474)<3,"",AVERAGE(IF($A$4:$A473=$A474,IF(ROW($A$4:$A473)>=LARGE(IF($A$4:$A473=$A474,ROW($A$4:$A473)),3),$G$4:$G468))))}

it should be: {=IF(COUNTIF($A$4:$A468,$A469)<3,"",AVERAGE(IF($A$4:$A468=$A469,IF(ROW($A$4:$A468)>=LARGE(IF($A$4:$A468=$A469,ROW($A$4:$A468)),3),$G$4:$G468))))}

In effect it is moving part of the formulas down 5 rows!
How do i stop the refresh doing this to all my formulas??

Any help greatly appreciated
Many thanks
Richard
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

Forum statistics

Threads
1,203,072
Messages
6,053,377
Members
444,659
Latest member
vuphihung

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top