HACKER Q&A
📣 zak10

How do you handle self-serve reporting for end users?


Every company I've been at has asked for some form of "let a customer build their own reports from our data" and I constantly find myself reinventing the wheel. Are there any systems you've used to allow custom report creation in a self-serve manner for end users? Design patterns you follow?


  👤 Nextgrid Accepted Answer ✓
An idea I was recently thinking about would be to prepare an (SQLite?) DB with all the data the customer is allowed to access (whether their own data, or proprietary data they're licensed to access and extract) and then let them run raw queries.

The advantage of using SQLite (as opposed to your primary DB) is that you don't have to care about sanitizing the queries or ensuring they don't see what they're not meant to because the user-specific DB only ever has data they are allowed to access, so even allowing them to run raw queries against (or download the whole database file) would be fine.