Skip to main content
Find Writers Products Industries Plans Become a Writer 1 (866) 501-3116 Sign In Get Started

Products

Blog Posts Press Releases Web Pages Product Descriptions Newsletters
Transcriptions Social Media Posts Video Scripts Custom Projects Content Tune-Ups
Ad Copy Ebooks Editing Q&A Content Whitepapers
Facebook Post Instagram Post

Industries

Agriculture Art & Design Automotive Building Materials Cannabis Career Construction Counseling Customer Service Dental Education Energy & Environment Engineering
Fashion & Beauty Family Practice Food & Beverage Gaming Health & Wellness Healthcare Higher Education Home & Garden Human Resources Injury Law Interior Design IT & Security
Insurance Legal Manufacturing Media & Entertainment Medical Law Nutrition Parenting Payments Personal Finance Real Estate Relationships
Retail & Ecommerce Religion & Spirituality Restaurant and Bar SaaS Sales Senior Services Software Sports & Fitness Technology Transportation & Logistics Travel
x Close Menu Find Writers Products
Blog Posts Press Releases Web Pages
Product Descriptions Newsletters Transcriptions
Social Media Posts Video Scripts Custom Projects
Content Tune-Ups Ad Copy Ebooks
Editing Q&A Content Whitepapers
Facebook Posts Instagram Posts
Industries
Agriculture Art & Design Automotive Building Materials Dental Gaming Fashion & Beauty Family Practice Cannabis Career Construction Counseling Customer Service Injury Law Interior Design IT & Security Retail & Ecommerce Education Energy & Environment Food & Beverage Personal Finance Healthcare Health & Wellness Higher Education Home & Garden Human Resources Transportation & Logistics Insurance Legal Manufacturing Media & Entertainment Medical Law Nutrition Parenting Payments Real Estate Religion & Spirituality Restaurant and Bar SaaS Sales Senior Services Software Sports & Fitness Technology Travel Relationships Engineering
Plans Become a Writer Login Get Started 1 (866) 501-3116
  1. Blog Home
  2. Software & Technology
  3. Scripted Writers
  4. Easy Slack SQL Reporting (Scripted Behind the Scenes)

Easy Slack SQL Reporting (Scripted Behind the Scenes)

Easy Slack SQL Reporting (Scripted Behind the Scenes)

We use Slack at Scripted. We use it for the normal use - communication, but also use as our reporting hub. 

One of our favorite tools that helps us is SQLBot.co, a simple service that lets you query your reporting databases and push the results into Slack.

Let me show you with an example. One of the most important things we offer at Scripted to our customers is our pool of freelance writers. Better writers produce better writing and create happier customers. Makes sense.

We like to watch our stats daily (if not more often) at Scripted, and the easiest way to do that is to have reports automatically publish into Slack. Once there we can discuss the results and take action if necessary.

Here’s a query I wrote (yes, I still pretend to code) that tells us the number of new writer applicants we get by day:

SELECT
to_char(w.created_at AT TIME ZONE '-5', 'YYYY-MM-DD') as day,
COUNT(DISTINCT w.id) as writer_accts_created
FROM users w
WHERE w.user_type = 'writer'
GROUP BY to_char(w.created_at AT TIME ZONE '-5', 'YYYY-MM-DD')
ORDER BY to_char(w.created_at AT TIME ZONE '-5', 'YYYY-MM-DD') DESC
LIMIT 30

I use Postico as my SQL editor, and here’s what the results look like in its interface:

sql results postico
That's a lot of writers!

Great, so how do I now get this info into Slack?  I could use some complicated ETL process or expensive reporting tool, but why do that when a simpler tool exists.  Enter SQLBot.co. 

Getting results into Slack is as easy as setting up my DB connection, then copying and pasting my SQL into SQLBot and setting a few preferences.  Here's what the new report screen looks like filled out for this report.

new-report-sqlbot.png
Creating a new report in SQLBot.co

slack-scheduling-sqlbot.png
Setting up Slack scheduling and command word

Now that I've set up the command to call the report in Slack, all I need to do is hop over and call it.  Here's what it looks like in Slack:

sql slack
Results!

So there you have it.  Simple, easy, fast Slack SQL reporting.  I can schedule this report to post daily or weekly, which makes things automatic, and means I won't forget to do it.  


Published by Scripted Writers on Friday, August 9, 2019 in Software & Technology.

Sign Up For Your 30 Day Free Trial Today!

You agree to Scripted’s Terms of Use and Privacy Policy.
Already have an account? Login
©2011-2022
Our Company
About Us Privacy Terms of Use GDPR Trust
For Members
Enterprise Agencies Publishers Customer FAQs Newsletter Customer Sign In
For Writers
Writer Services Agreement Writer FAQs Writer Sign In
Additional Resources
The Scripted Blog Industries Podcast Technology Affiliates Competitors
Social Buttons