Author: way0utwest

  • Exporting Lists in SQL Multi Script

    SQL Multi Script is a lesser known tool from Redgate Software that is designed to easily allow you to run scripts against many server instances with one click of a button. It’s similar to a Central Management Server, but it returns results a little cleaner, and has a few extra features that make things run better. I have a number of customers using this to deploy to many instances, both for database changes and instance config updates.

    Recently a customer wanted to share their distribution list with another person on their team. They asked how to do this, and it turns out to be very simple.

    We’ve built import and export into the tool. I’ll look at how you can do this.

    First, open SQL Multi Script and then pick the tools menu. Here you will see the export and import items, as shown below.

    2021-07-13 11_13_32-SQL Multi Script - New Project_

    If I pick export, I get a dialog that shows the distribution lists I’ve created.

    2021-07-13 11_13_25-Export Distribution Lists

    I can pick all, one, or a group of them. Note that all of these are exported into a single file, which is useful if I can want to share all my lists with a colleague.

    Once I click “Export” I have to choose a file name and location from a standard Windows Explorer dialog. I always think about how I’d sort these in a large list, so I like to pick something that will make sense in a month. In this case, the app and then the list..

    2021-07-13 11_14_09-Save As

    Once I click OK, the file is created, and I can see it in the file system. Here I’ll open it in Sublime Text to see what it looks like.

    2021-07-13 11_14_28-Documents

    The file is XML, which isn’t ideal, but it it easy to read. I have my XML file below, with all instances using Windows Authentication. If I had used SQL Auth somewhere, this would end up with an encrypted password, which I assume SQL Multi Script can import and decrypt. Here is my file:

    <?xml version="1.0" encoding="utf-16" standalone="yes"?>
    <!--
    SQL Multi Script
    SQL Multi Script
    Version:1.5.4.1390-->
    <databaseListsFile version="1" type="databaseListsFile">
       <databaseLists type="List_databaseList" version="1">
         <value version="2" type="databaseList">
           <name>MixedAuthList</name>
           <databases type="BindingList_database" version="1">
             <value version="6" type="database">
               <name>AdventofCode</name>
               <server>(local)</server>
               <integratedSecurity>True</integratedSecurity>
               <connectionTimeout>15</connectionTimeout>
               <protocol>-1</protocol>
               <packetSize>4096</packetSize>
               <encrypted>False</encrypted>
               <selected>True</selected>
               <cserver>ARISTOTLE</cserver>
               <readonly>False</readonly>
             </value>
             <value version="6" type="database">
               <name>dlm_3_qa</name>
               <server>LOCALHOST</server>
               <integratedSecurity>False</integratedSecurity>
               <username>Joe_Admin</username>
               <savePassword>True</savePassword>
               <password encrypted="1">25eJUgEGChcaG13SEpATBg==</password>
               <connectionTimeout>15</connectionTimeout>
               <protocol>-1</protocol>
               <packetSize>4096</packetSize>
               <encrypted>False</encrypted>
               <selected>True</selected>
               <cserver>ARISTOTLE</cserver>
               <readonly>False</readonly>
             </value>
             <value version="6" type="database">
               <name>dlm_2_integration</name>
               <server>LOCALHOST</server>
               <integratedSecurity>False</integratedSecurity>
               <username>Joe_Admin</username>
               <savePassword>True</savePassword>
               <password encrypted="1">25eJUgEGChcaG13SEpATBg==</password>
               <connectionTimeout>15</connectionTimeout>
               <protocol>-1</protocol>
               <packetSize>4096</packetSize>
               <encrypted>False</encrypted>
               <selected>True</selected>
               <cserver>ARISTOTLE</cserver>
               <readonly>False</readonly>
             </value>
           </databases>
           <guid>4e255407-343c-4b88-a54a-4e981ad2beac</guid>
         </value>
       </databaseLists>
    </databaseListsFile>

    This is a useful feature for sharing lists in a team. It’s a little clunky, but it works well.

    If you’ve never given this a try, download SQL Multi Script today, or get the Toolbelt and give it an eval. You might find it’s quite handy.

  • Seriously Real Time Data Processing

    There are many of us that work with systems where data is processed in real-time and then used to make decisions. These might be humans viewing reports and then taking action, or some automated system that might react based on a value changing. In many cases, however, the amount of data, timing in which to react with a decision, and the implications for mistakes aren’t that critical. We have some leeway for the processing not being perfect.

    For vehicles traveling at 180mph, the tolerance for mistakes is low, with the chance of a catastrophic crash looming constantly. That is what is happening with a competition at the Indianapolis Motor Speedway, where university students are competing to develop race cars that can move around that track at these speeds. This would be quite a challenge for vehicles moving around the track by themselves, but in this case, it’s a race with multiple cars.

    This might seem silly, but it’s a step towards understanding just how much data needs to be processed and how the results can deal with the chaos in the real world. Each car is independent, so has to react to the other vehicles and make decisions on how to adjust its own operation in real-time, with a sub-second response to prevent accidents. This isn’t different from the decisions human drivers have to make in a race, and there are plenty of mistakes that result in crashes. However, humans can think in new situations and react. They don’t need to have every possible response programmed in.

    These AI-driven race cars will be similar, but how well they perform remains to be seen. This is the type of test environment that will help us move forward in using technology and AI models in less constrained environments, like a public highway. Lots of technology was tried on race tracks before it became available to consumers, and I think this will make its way to retail cars as well at some point.

    There are already some companies trying to build this into cars. Tesla famously has Full Self Driving, although this has been in beta for a long time, and its results are less than stellar in some cases. Waymo has been working on the problem, and I actually had the chance to ride in a self-driving Uber in Las Vegas, though that experience was less than thrilling. The driver had to take control a number of times, so this wasn’t quite self-driving.

    There is a lot of work still to be done here, and I don’t know how quickly this will become safe enough for general driving. I suspect that we’ll see this in very limited areas first, like a zone in a city that only allows these types of cars, or maybe specific highways, like HOV lanes. Somewhere the problem domain is simpler, with less decisions that need to be made.

    There are already lots of safety features in modern cars that help prevent mistakes and accidents, but most of these are simple systems that aren’t making decisions in many ways. Moving to more complex driving operations will require some heavy data gathering, processing, and analysis, something that should be of interest to data professionals. This is a problem domain that will be fascinating to watch in the next few years.

    Steve Jones

    Listen to the podcast at Libsyn, Stitcher, Spotify, or iTunes.

  • Daily Coping 19 Jul 2021

    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. All my coping tips are under this tag. 

    Today’s tip is to start the week with some movement. Exercise in some way today.

    An easy coping tip for me, as this is something I regularly do. I’m writing this a few days early, but in this case, I’ve scheduled a yoga class for Monday afternoon. Now that it’s on my schedule, I’ll get up early, get to work and be ready for a break after.

  • Service for Brian Moran

    If you are in the Reston, VA area and would like to attend, the service information is here: https://www.eventbrite.com/e/brian-morans-celebration-of-life-tickets-163260712185?fbclid=IwAR3uwlJgfqXJrQf998pyGaZtyDupT_Vi6mwQIqaVufV9cJkNMfi-6LmrA7w

    Also, if someone going can livestream, there are quite a few of us that would appreciate you doing so.