How do I Select Data from Google Sheets?

In my application I need to connect with three spreadsheets from gooogle sheet, one is State, Capital and cities but I would like to know how to select a State and show me its capital and cities by means of its ID that are in different spreadsheets
Could you help me? Thanks a lot

Start here:

Here is an example of how to coordinate the loading of multiple external tables, one at a time.

You would have to switch it from loading from files to downloading csv tables as described in one of the Google Sheets posts, and do your searching from there on.