【发布时间】:2021-11-07 21:53:28
【问题描述】:
我有一个 WebApp,它通过 google.script.run.withFailureHanlder(data).withSuccesHandler(data).someFunction(data) 发送一些属性来过滤从云端硬盘中的电子表格中检索数据。例如
主机端
google.script.run.withSuccesHandler(e => {
console.log(e);
}).someFunction(data);
Google Apps 服务器端:
function someFunction(data){
let book = SpreadsheetApp.openByUrl(url).getSheetByName(data.name);
let info = book.getDataRange().getDisplayValues().filter(x => {
return new Date(data.start) > new Date(x[0]);
});
return result;
}
多人同时查阅这些电子表格。一开始还不错,但是现在数据增长了很多,查询也因为数据量变慢了。
有什么办法可以优化这些查询而不影响其他人同时查询的结果?
【问题讨论】:
标签: javascript google-apps-script google-sheets web-applications