I'm looking for recommendations for either software (or a book) with lot's of cool SQL queries. The one's you use to view data in way's you'd see in a management board meeting.

The software should be able to use any general Database like "Northwind Traders" and apply a bunch of generic queries with different types of grouping and aggregates to give you idea's on how to layout data differently.

Sure I know about inner, outer, left, right & etc joins...

left join event_attendee ea on ea.employeeid = e.id
left join certification c on c.pid = e.username
inner join event ev on ea.eventid = ev.id
inner join company co o

I know how to do sub queries and switch cases:

select display_name, co.username, co.email,
coalesce((select Count(*) from event ev where ea.eventid = ev.id),0) as TrainingCount,
coalesce((select Count(*) from certification c where c.pid = e.username),0) as CertCount,
(case when c.cert = 'practitioner' then 1 else 0 end) Practitioner,
(case when c.cert = 'builder' then 1 else 0 end) Builder,

Or a few levels up the hierarchy

where supervisor in (select userid from company where supervisor in (select supervisorid from company where userid = 123))

I know there's loads of charting app's and analytic databases with filtering but I'm looking for plain old SQL queries. Surely there's some good app's out there.

The database is a bit over 1GB and excel doesn't cut it, even with Power BI. I can put the data in a database, but am running out of idea's on how to display it and am looking for best practice's. And buying is usually better than building.

The data could be for any type of business, so long as the software shows the best way's (or give good idea's) to view the data.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.