When working with Google Sheets, you can define granular, user-based rules for editing worksheets, columns, and rows within a spreadsheet. Unfortunately, there's no way to restrict read access. This would be very helpful in many scenarios, for example, to show your customers only the tickets relevant to them, or your employees only the projects they're working on.
One possible solution is to create a so-called master sheet and use IMPORTRANGE to access selected data from it in one direction. Unfortunately, this involves a lot of manual work: creating new sheets, assigning file permissions, developing and implementing the IMPORTRANGE formula, accepting permissions, and setting formatting. If the structure or format changes, this must then be done manually for each spreadsheet individually.
The following Google Apps script does this automatically. If you execute the init () method once in the mastersheet, all slave sheets are automatically created, rights are assigned and formulas and formatting are set. If data in the master sheet change, it is automatically mirrored in the slave sheet. If the structure of the master sheet changes, simply execute init () again (previous sheets are automatically updated).
82ba709df04366e65cb3a42f84f19631