Read data from Google sheets

Also see:

1 Like

I tried but still can't run

Please check the code for me, and sheet and Sheet (in uppercase and lowercase) I have corrected but still not working

Please check the code for me, and sheet and Sheet (in uppercase and lowercase) I have corrected but still not working

It appears that your sheet is called Sheet but you are sending sheet1 in the blocks

1 Like

Try Sheet, with a capital "S."

2 Likes

I make google sheet data query, i tried my best. however, it still does not work. Can anyone help me see if there is an error, the code, or do I need to install any additional google sheets add-ons?

What query are you trying ?

Are you sure you have your google apps script published and your script url in your app is the same?

1 Like

I've fixed it many times, but still can't get the query. #ERROR announcement!
https://script.google.com/macros/s/AKfycbzAXLlAO0XBsq1Ms98hES9wuTO03i72yXJC-mMEFbZGdq_TwQ/exec
17KQxRL-HALgY9etgTqa_mo4jXDYu_dlxTMka8d3w2ec

i don't know where it went wrong this is my google sheet

There is a problem with your google apps script web app. It could be an issue with your locale. Try changing this line in your script:

 var qry = '=query(' + rg + ';\"' + sql + '\";1)';

you will see I have replaced the , (commas) with ; (semi-colons).
Remember to deploy your script to a new version

If you run this in your computer browser you will see the data is returned in a table:

https://docs.google.com/spreadsheets/d/17KQxRL-HALgY9etgTqa_mo4jXDYu_dlxTMka8d3w2ec/gviz/tq?tqx=out:html&tq=SELECT%20*
4 Likes

I did it, thank you so much

how can i view it as a table on the phone screen. by column on google sheet trangtinh

I would use @Ken's Tableview extension, but you can use a webview with a javascript dynamic table, or make a table with labels

3 Likes

i want to represent the data from my query as a table. can you help me.

Here is a tableview example

TableViewExample.aia (19.8 KB)

To get the display correct, ensure you set the Cell delimiter and Row delimiter options in the Tableview designer properties, and also see the checkboxes for Shrink to Fit and Stretch to Fit.

2 Likes

Replace the commas in the header with semicolons (";").

1 Like

how can i display the data in the "Address" box to the size i want, or the data can be newline