KT12
KT12

Reputation: 1

How can I use Query() and Flatten() in Google Sheets to reference a variable amount of rows?

I'm looking to take a data download in this format current data

It is the Item ID, Value, Date changed to that value for the history of that Item. Each Item has been changed a different number of times.

I'd like it to look something more like this. how Id like the data Where each Item ID with the value and the date changed to the value having their own row.

I've tried to use different forms of Query() and Flatten() but can't seem to get it right as I am quite a novice at this.

I attached my sample sheet - I'd really appreciate the help https://docs.google.com/spreadsheets/d/1SvlOX7D57_V3FnYNsKAAmDMvnUv5jEZgr79_593atdw/edit?usp=sharing

Upvotes: 0

Views: 1031

Answers (1)

player0
player0

Reputation: 1

use:

=INDEX(QUERY(SPLIT(FLATTEN(Data!A2:A&"×"&Data!B2:Y&"×"&Data!C2:Z), 
 "×",, ), "where Col3 > 44444"))

enter image description here

Upvotes: 1

Related Questions