Author: way0utwest

  • Automation Ideas for T-SQL Tuesday #130

    tsqltuesdayThis month we have another great T-SQL Tuesday topic, and again, a host that I pressured into writing the invitation. Elizabeth Noble (@SQLZelda) and I were talking DevOps last year at a SQL Saturday, just as she was effecting some change at her employer. At an event later in the year, I challenged her to host, and here we are, with a great topic, Automation.

    That’s this month’s invitation. Elizabeth describes the process of using automation to smooth out their deployments to SQL Servers. They slowly built a CICD pipeline and migrated projects over and over to save her time.

    This month, what have we done to automate things? I have a few stories.

    Automating Data Collection

    One of the things that I am passionate about is the SQL Saturday events. I loved that PASS maintained a site, and made a feed of event data available, but over time, we’ve lost some data and I don’t think there is much impetus to maintain this over time.

    As a result, I build an automated process to grab data from the feeds and save it as an XML file on my local machine. I have the basic code up at GitHub, though I need to improve and refactor it a bit. These files change as the organizers update them, so I need a good merge process. Right now I tend to delete all 1-2KB files periodically, as the file is built once the event is approved. However, until all the speakers and sponsors are scheduled the file size is just a few KB. Most events are > 100KB once they are set.

    This is a basic way of grabbing some data, and I’m looking to build a few more data collection processes to grab data in my life and keep it around, just in case some service I use goes kaput.

    Automatic Databases

    I work at Redgate, and one of the things I’ve been spending more time doing is the automation of databases for development with the latest code and test data. This is a challenge, but a few of the things that I’ve done with Redgate that help are as follows:

    1. Use Powershell to automate the creation of SQL Clone images.
    2. Use PowerShell to update SQL Monitor alert values and add instances
    3. Use Flyway in a container to deploy changes
    4. Use our SQL Change Automation cmdlets to deploy changes to databases

    All of these items can be automated so that a user just needs to run a script, or sometimes just click a button.

    I’m slowly getting the PoSh code up on GitHub as I build demos and help customers get things done. Right now, getting organized is the biggest part of my job, because I find these questions coming over and over.

    I’m a bit proponent of DevOps and automation. Use tools and computers to do the tedious, repetitive work. Keep your day focused on solving problems and building/improving scripts.

  • Daily Coping 8 Sep 2020

    I started to add a daily coping tip to the SQLServerCentral newsletter and to the Community Circle, which is helping me deal with the issues in the world. I’m adding my responses for each day here.

    Today’s tip is to free up time in your diary by cancelling any unnecessary plans.

    I keep busy. In fact, I rarely take a day off from everything. If not work, I coach, I look to exercise most days, and even on weekends I look to tackle at least part of a project at the ranch.

    That being said, I have started to try and find days where I don’t plan things. I might tackle less things, since I’m disinclined to just sit around, but I won’t make a goal for myself and I might just wander through part of a project or a chore.

    I’ve also taken to cancelling plans at times to free up a few hours of life. Maybe I’ll cook something, or play guitar, or watch a movie, but when I have more than 3 scheduled things in a week, I might look to cancel one or two to find time to unwind a bit.

    I did this recently, when my wife and I were scheduled to go out with a friend. With multiple things on our schedule, we agreed to reschedule and push things back a couple weeks.

    Downtime is good, even if I don’t always want to take it.

  • Labor Day 2020

    Most of this year has been a labor for me, just moving from day to day. The year started out well, and I was excited at first. I didn’t think much of COVID-19, assuming this would go the way of SARS, H1N1, etc., with relatively little impact to me. I laughed about it with family on a trip to Las Vegas in February.

    Was I ever wrong.

    Today is Labor Day in the US, a holiday for those of us here. This was a holiday to celebrate those that work in trades and unions. While those of us in technology aren’t often considered labor, as many of us as salaried individuals, we do toil away in what has become a daily grind, albeit a creative one. In the US, this is also the unofficial end of summer, marking the time when many are starting, or about to start, another year of schooling.

    I started the coping tips on my blog partially to help the community, but also as a way for me to find ways to deal with the massive changes in life. Despite being an introvert, I do enjoy small doses of meeting other people, being in society, and traveling. All of those have ended for the time being, and finding different ways of coping have helped me during the last six months.

    Today, whether you’re working along, or reading this on a Tuesday when you get back, I hope you take a moment and reflect on how life has changed across this year. Whether you like or dislike things, you’ve struggled or sailed through, I’m sure there is a lot of emotion.

    I’d ask that you consider having empathy and compassion for others. None of us experiences this the same way, and what might feel like a burden or a trivial event could be tremendously different for others. Even those in my household have all had vastly different reactions to the same event, news, conversation, etc.

    I appreciate seeing different points of view and try to respect why others might see the world in a different way from me, but mostly I appreciate the positive messages. I like seeing Chris put out positive ways to start the day. I appreciate Hamish’ message of kindness, something I hear during every cherished opportunity to shake his hand. I appreciate Anthony’s joy of cooking for his family. Meagan’s singing brightened my day. Mala’s quick messages and pictures on FB make me smile. There are many more moments of thought, positivity, and joy that I’ve found, even while struggling.

    We are all having good and bad days, up and down times, but most of us are here for each other. Reach out, say hi, check in, and remember that you have friends, even if you can’t celebrate with many right now.

    Steve Jones

    Listen to the podcast at Libsyn, Stitcher or iTunes.

  • Daily Coping 7 Sep 2020

    I started to add a daily coping tip to the SQLServerCentral newsletter and to the Community Circle, which is helping me deal with the issues in the world. I’m adding my responses for each day here.

    Today’s tip is to be willing to share how you feel and ask for help when needed.

    I struggle with this. I’ve grown up fiercely independent, even with family. I’ve had to work hard to make my way in the world, and I tend to try to do things myself.

    However, I know that’s not completely healthy, and I need to get help at times. During this pandemic, I’ve tried to remember this, and during a particularly hard time recently, I just had to walk away from something and ask my wife for help. I almost didn’t, but I am glad that I did. It was a relief and good.

    I need to do this more, and find ways to not only continue to support and help others, but also reach out and let others help me.