我在一个sheet A
中有多个点击,每个点击有5000+行,一些行有相同的内容,希望找到特定的行,同时输入内容并复制那些与不同sheet B
匹配的行,并将格式设置等从sheet A.
保留
Example:
I need to make a shipping/order list
I have 2 sheets Sheet A
is full of information (my stockload), multiply tabs with a lot of rows in each tab. in Sheet B
(new URL) I want to filter the information.
Lets say, I have 5000 articles spread in 5 tabs on Sheet A
, someone is ordering 20 articles, so I just want to scan the EAN or any other code on that article to Sheet B
, and all rows with that data, will be imported. Now I have a brand new list with only the 20 articles, which I can share to the client.
I have tried with script:
function copyRowsWithCopyTo() {
let spreadSheet = SpreadsheetApp.getActive();
let sourceSheet = spreadSheet.getSheetByName('Sheet0');
let sourceRange = sourceSheet.getDataRange();
let targetSheet = spreadSheet.getSheetByName('Sheet1');
sourceRange.copyTo(targetSheet.getRange(1, 1));
}
还try 使用Importrange查询,但我似乎无法找出关键代码,以便在所有选项卡中搜索,并查找/匹配我始终提供的新文本/代码.
=QUERY(IMPORTRANGE("https://docs.google.com/spreadsheets/d/1hAeUokEf-1DQjRYn2iQXCSCwAoRW-C083z5QYXpzq-Y", "1:1000"), "B2 ",0)
有人知道我错过了什么吗?