Limit if data in Google Apps Script connected with Google Sheets - google-apps-script

Is there any limit of data between Google Sheet and Google Script?
I know about quotas of apps script, my question is if a limit of the number of rows exists when you edit a big google sheet from Google apps script.
My problem is:
I take like 1000 rows x 30 cols from Google Sheet with SpreadsheetApp and i put that in an Array is Google Apps script, then I make some conditionals in Javascript to detect some stuff, and then I edit that sheet (with 1000 rows x 30 cols) with google apps script and SpreadsheetApp. My script works well many months with data like 200 rows x 30 columns but now with x5 data my script is failing. The script is not reporting an error, it just make the edition really wrong. It would be possible the amount of data?

I haven't seen this happen, but I can't ensure that this isn't a bug. If you have a Workspace account you can contact Google Workspace Support and ask them to take a look into it.

Related

Take data from a Google sheet with Google App Script and organize it in a Google doc

In Sheets I have dates and events that I would like to publish in Docs with the events listed under MONTH - YEAR. The number of events can vary, though usually over 400 events over a 2 year period. Sheets has them all sorted, but I haven't programmed in JavaScript before as I have used Access to do this in the past (But it seems to be overkill to have Access just for this.) It seems that Google App Script is the only way to do it?
A sample of the Sheet is here https://docs.google.com/spreadsheets/d/1IYmdIZU9wEVgSr7l4UWzJE7xXgUEQQOHUVarBHCeWgI/edit?usp=sharing
A sample of the doc that I would like to make is here https://docs.google.com/document/d/1obF-OiRAQG_6WxwiCT5-GkvnjETsdYiMHB2SDGxDeKA/edit?usp=sharing
From the question
It seems that Google App Script is the only way to do it?
Besides Google Apps Script, there are APIs for Google Sheets and Google Docs that you could use with several programming languages. For more details see
https://developers.google.com/docs
https://developers.google.com/sheets

Can I use Google Apps Script instead of Formulas for doing calculations on a spreadsheet?

Is Google Apps Script faster than FORMULAS for calculating sum or
sumif in a spreadsheet which has around 10,000 rows?
How does FORMULA work?
I know Google Apps Script executes its code in the cloud, but is there any way for that to work client-side just like JavaScript?
Is Google Apps Script faster than FORMULAS for calculating sum or
sumif in a spreadsheet which has around 10000 rows?
No
How does FORMULA work?
Client side, can cause desync issues but refreshing the page brings you back to what everyone else sees. So there is actually a server side and client side execution of these formulas to a certain extent
I know Google Apps Script executes its code in the cloud, but is
there any way for that to work client-side just like JavaScript?
No

Is it possible to use IMPORTXML function and modify it with a query?

I am creating a spreadsheet portfolio. I came across some limitation, e. g. that I can not automate the process of importing the data from a website for different stocks. This is since the Index for the stock information on the website is often different from another stock. However there is the pattern that it is the next Index from a defined string e. g. "Branche". This made me wonder if I can automate the process with the Google Apps Script.
I wrote down the steps at first in Google Sheets. Then I formulated the steps in the Google Apps Script. Now I am stuck.
Step 1
=IMPORTXML("https://www.comdirect.de/inf/aktien/detail/uebersicht.html?ID_NOTATION=9386126";"//tr/td[#class='simple-table__cell']")
Step 2
=IMPORTXML(CONCATENATE("https://www.comdirect.de/inf/aktien/detail/uebersicht.html?ID_NOTATION=";"9386126");"//tr/td[#class='simple-table__cell']")
Step 3
=INDEX(IMPORTXML(CONCATENATE("https://www.comdirect.de/inf/aktien/detail/uebersicht.html?ID_NOTATION=";"9386126");"//tr/td[#class='simple-table__cell']");62;1)
Step 4 final product - just an idea not working yet
function import_branche() {
var url1 = "https://www.comdirect.de/inf/aktien/detail/uebersicht.html?ID_NOTATION="
var ulr2
var ticker = "//tr/td[#class='simple-table__cell']"
Index = find the INDEX with the String == "Branche"
return Index(IMPORTXML(CONCATENATE(url1;url2); ticker);(Index+1);1)
}
Ideally, I would like to have a function where I only need insert the link of the website and get the result. Here is the index for the information automatically found.
Google Apps Script can't execute Google Sheets spreadsheet functions like IMPORTXML, so you have two basic alternatives
Use Google Apps Script to get the result of a IMPORTXML formula from the spreadsheet, then use JavaScript to do the rest of the job
Do the job completely using Google Apps Script and JavaScript
Related
Google docs ImportXML called from script
(javascript / google scripts) How to get the title of a page encoded with iso-8859-1 so that the title will display correctly in my utf-8 website?

Upper limit to number of collaborators in Google Sheets with Google Apps Script

Just wanted some guidance on how many users can access a Google Sheet before it starts to slow down?
Let's say there are 10 sheets each with 10,000 cells, and the sheets contain functions using both Google Sheets and Apps Script.
Thanks.

How to use ImportXML in a Google Script?

Scenario:
I am trying to use Google spreadsheet to do something like this:
I've a set of Blog URL's (more than 50) for which I want to fetch title
Currently I am using the formula: ImportXML(A2,"//h1[#class='entry-title']" )
The Problem w/ this approach is that ImportXML calls are limited to 50 per spreadsheet and I've more than 50.
I browsed/searched - found out that we can use ImportXML calls in google apps script but did not found any example.
I found this: https://developers.google.com/apps-script/articles/XML_tutorial but I was hoping to use ImportXML function.
Can anyone describe or point to a resource where they have used ImportXML in a google apps script? Thanks!
I would use a few spreadsheets, then pull the results together into a master spreadsheet, or are you doing >1000 or so. If you have lots, the XML_tutorial link you have is the place to start.
But last time I checked, google-apps-script does not support google spreadsheet functions, if I remember, the feature request to support all spreadsheet functions in GAS was rejected.