Dynamic Validation but with Columns - excel-formula

I am trying to do a dynamic data validation list using row 5 and adding columns as data is added to those columns. So I have googled and found lot's of offset formulas that are designed to offset on rows but my data is in columns (D5, E5, F5, G5, H5, etc ....).
I tried adapting this formula but it doesn't give me what I want:
=OFFSET('Borrower Database'!$D$5,0,0,COUNTA('Borrower Database'!$5:$5),1)
I want my list to read from the columns on row 5 and dynamically grow as I add more names to the next columns.
Can anyone tweak this formula for me?

You are almost there :) Look at OFFSET function definition. In your formula [height] is swapped with [width]. Corrected formula:
=OFFSET('Borrower Database'!$D$5,0,0,1,COUNTA('Borrower Database'!$5:$5))

Related

Add text into cell formula in Excel to automatically select an other column with a drop down

This is quite an unsual question to fix my column problem from my Power Query mess.
I would like to add a text value to a selection name so it will dynamically select an other column name.
My goal is that my drop down would automatically do the following on every row from an other sheet:
=TableItems[#high]
=TableItems[#high.1]
=TableItems[#high.2]
What I want it to look like with dynamic drag formula
Anyone know if it is possible to add a value to a cell selection without having any errors?
I was able to offset my column by using a new column which I have called "Formula" and I just hide it.
This is the procedure I have done:
I took my TableItems selection and I have created a OFFSET formula of
=OFFSET(ItemInfo!D2,1,**4**,1,1)
The number 4 in my table moves 4 times to the right each times, so I have created a formula to multiply the number 4 by 2,3,4,5,6 etc.
The formula is the following:
=OFFSET(ItemInfo!D2,1,$H3,1,1)
=OFFSET(ItemInfo!D2,1,$H4,1,1) etc etc etc
IMAGE OF THE RESULT
I've had this problem for a couple of centuries, but I really hope this will help anyone else having a similar problem.

How can I create a table in Excel from a spreadsheet that contains data that is grouped in rows

I have a thousands of rows of here data in a spreadsheet (excel 1 image) that I need to create a table with the data populated across the headers below.
If you don't want to use a VBA or spend time with other custom queries, you can do something like this (not, need to create helper column):
Create a helper column that does a count if:
Using this formula:
=IF(B2="Facility ID:", COUNTIFS($B$1:B2,"Facility ID:"),"")
Then structure your data table like this:
And you can use this formula (starting in cell I7):
=INDEX($A:$E,MATCH($H7,$A:$A,0)+I$4,I$5)
Then all you need to do is drag down the rows and increment the counts and it should work provided that the spacings always stay the same and the locations of the fields also stay the same
This solution requires a version of Excel that supports XLOOKUP and Dynamic Arrays.
I would add two columns. One to count records and one to count the line number of the record like so.
E2 is =IF(A2="Facility ID:",MAX(E1:$E$1)+1,E1) and F2 is =IF(E2=E1,F1+1,1). Those formulas are dragged all the way down with the exception of the last row. That is a 6 manually entered because the typical 4th and 5th line are missing from that record.
Then sheet2 looks like this.
A2 counts the number of total rows of data in sheet1. =COUNT(Sheet1!E:E)
Rows 3 and 4 show the positions of each field within the record.
A6 starts a list from 1 to number of records. =SEQUENCE(MAX(OFFSET(Sheet1!E2,0,0,B1))) This uses the dynamic array functionality to spill into multiple cells.
The formula in B6 spills into multiple cells as well.
=XLOOKUP($A6#&B$3,OFFSET(Sheet1!$E$2,0,0,$B$1)&OFFSET(Sheet1!$F$2,0,0,$B$1),OFFSET(Sheet1!$A$2,0,B$4,$B$1),"")
I used OFFSET in the formulas so they can update if additional data is entered.
Finally, copy the formula in B6 to the other columns.

Excel Index & Match vertical and horizontal criteria for copying formula

I have been trying to populate the following table:
with order_amount from the following table:
I cannot crack the fact there is a second condition to be taken into account - column delivery_week.
Can somebody please help me out with a formula so it can be used across the weeks in table Final?
I have tried with Index+Match. The issue is, one condition is to be looked up horizontally (product_id) and second (Deliver_week) vertically
The end result is shown here:
I would appreciate any tips..
PS: The table structure has to stay as it is - shown tables are just necessary columns to solve the problem.
as stated in the comments use SUMIFS. Put this in C2:
=SUMIFS(OtherSheet!$C:$C,OtherSheet!$A:$A,$A2,OtherSheet!$B:$B,C$1)
And copy over and down.
In the order_amount table, try to create in D:D an assisting column which concatenates both columns A and B, i.e. (A2&B2).
Go into columns C2 in your target table and write something according the following:
(assuming order_amount is in worksheet - "sheet2")
=INDEX(Sheet2!$C:$C,MATCH($A2&C$1,Sheet2!$D:$D,0),0)
Pull this formula to the other rows and columns to populate them, the formula is fixed, thus don't worry for changes. To replace N/A with "0" use:
=IFERROR(INDEX(Sheet2!$C:$C,MATCH($A2&C$1,Sheet2!$D:$D,0),0),0)

How to get the rows which has a value greater than a number across all columns in excel sheet?

I am newbie to the excel formulas.I have an excel sheet which has lets say 100 rows and 100 columns. columns have different values from 0 to 20. I want the rows where any of the column value is greater than 10.
How to ignore the hidden columns, if these are in the range, without modifying the range? I mean based on some IsHidden kind of property?
Something simple like:
Formula used in F1:
=IF(COUNTIF(A1:E1,">10")>0,TRUE,FALSE)
If you have data in 100 columns from A to CV, put this at the top of an empty column (CW1) and fill down:
=MAX(A1:CV1)>10
You could try:
=IF(MAX(A1:C1)>10,"Greater",IF(MAX(A1:C1)=10,"Equal",IF(MAX(A1:C1)<10,"Smaller")))
Image:
New Version as per request:
=IF(MAX(A1:B1,E1:F1)>10,"Greater",IF(MAX(A1:B1,E1:F1)=10,"Equal",IF(MAX(A1:B1,E1:F1)<10,"Smaller")))
You can't automatically ignore hidden columns in formulas, but you can automatically ignore hidden rows. If you transpose your data, using Copy > Paste Special, you can use this formula to test the maximum value ignoring hidden rows:
=AGGREGATE(4,5,A1:A100)>10
To understand the first two parameters, you can look at the help on the AGGREGATE function, or you can type out the function manually to get pop-ups lists that explain the options.

Formular dragging in Excel

I have a data of 1000 rows in Excel, and I wish to calculate the variance of every 10 data, say =var.s(A1:A10), =var.s(A11:A20), .....
I did the first two manually and tried to drag the formulas down, but instead of having =var.s(A21:A30), =var.s(A31:A40) I had =var.s(A3:A12), =var.s(A13:A22).
Could anyone please suggest how I can get my desired results?
If your values are in ColA you can use a formula like the one shown below: for each row you drag it down it will offset the range fed to VAR.S by 10 rows.

Resources