Author: way0utwest

  • SQL in the City Comes to Seattle in 3 Days

    Last week I spoke at SQL in the City 2015 in London, and it was a great event. We had a wonderful event, and I’m looking forward to Seattle. Lots of good questions and comments in my version control talk, good feedback on the keynote, which I really enjoyed. I thought our end of day panel was outstanding, and I wish we had 2 hours for that as the questions were amazing.

    I’m looking forward to a duplication of SQL in the City in Seattle on Monday, just a few days away. We’re going to be at the Hyatt in downtown Seattle, and we’d love to have you come. You can register and join us, but please don’t register unless you can come.

    There are also a few workshops in Seattle on Tuesday, so if you want hands on practice, come sign up for on of these.

  • Positive or Negative

    While watching a presentation recently on a SQL Server topic, I was surprised by a design technique that the speaker used. I hadn’t ever thought of the issue, but it caught my eye and made me rethink the way I look at design, and even data.

    In this case, the speaker was building a table and looking to make a row active or inactive. This person chose to use a column name of “inactive,” which surprised me. I’ve always used an “active” column if I am trying to mark a row in a binary fashion.

    That got me thinking. I wonder if there is some impact to designing entities either way, but I wanted to ask this question:

    Are you positive or negative. Would you use an active flag or an inactive flag?

    This could be extended to any other type of choice, but do you look to flag an action as happening, or not happening. As readable or not readable? As usable or ignored? I’m not sure it matters, but I’d certainly be curious if anyone has any reason why you might choose one or the other. Is there some meaning conveyed? Let us know this week.

    Steve Jones

    The Voice of the DBA Podcast

    Listen to the MP3 Audio ( 1.9MB) podcast or subscribe to the feed at iTunes and LibSyn.

  • Git Push in SQL Source Control

    I’m excited. Git support is growing in SQL Source Control and the release recently contains Git push/pull support. If you don’t see the release of 4.1.x, you need to update. The update should be available for everyone.

    I do like Git. I’m working with SVN, TFS, and Git on a regular basis. However I tend to prefer Git overall. Now I can do most things I want to do in SOC, which is exciting. No forgetting to push or the need to drop to the command line or another interface.

    The Git Additions

    In a previous post, I set up a link between a database and a Git repository. Let’s see how the Git push now works.

    I’ve got this database on my local instance.

    soc_git_push_2

    It’s linked with SQL Source Control to a local Git repository.

    soc_git_push_3

    Let’s change something. I’ll pop open a stored proc.

    soc_git_push_4

    Let’s make a simple, but real, change. I’ll add a NOCOUNT setting in there, which is a good idea.

    soc_git_push_5

    In the Commit tab for SQL Source Control, I see my change. Note that most everything looks the same here and I can see the code differences like I always could.

    soc_git_push_6

    Now I commit this change. In this case, it goes to my local Git repo, but isn’t pushed.

    NOTE: In the real world, I’d pull before I commit to be sure I wasn’t causing a merge issue.

    Once that’s done, my Commit tab changes.

    soc_git_push_7

    SQL Source Control (SOC) detects the change and knows we have an unsynced Git repo. I can now push the “Push” button. Once I do this, I get a warning if I haven’t turned this off. I turn it off, but you should always be aware that SOC isn’t managing your Git repo. It’s linking to it. If you make changes in the repo with some other app, like Visual Studio, the entire repo is pushed, not just the change SOC committed.

    soc_git_push_8

    Once this is done, I once again see a clean Commit tab.

    soc_git_push_1

    However, if I go to the remote repo, which is on GitHub in this case, I see my change.

    soc_git_push_9

    I love Git. I think it’s really cool, and it’s a great way to work with distributed Version Control. I am playing with TFS as well, but I prefer Git, and I think this support is great.

    There are still things needed, things I want, and more, so be sure you add your votes to the SQL Source Control UserVoice page and let the SOC team know what’s important to you.

    If you’re not using SQL Source Control, you might check it out and give it a try for a month: http://www.red-gate.com/products/sql-development/sql-source-control/

  • The Dangers of Travel

    I cross a lot of borders, and I have been worried at times about losing my electronic devices. There hasn’t even been an issue, but then again, I don’t really have anything of value other than the hardware. The bits themselves are fairly replaceable for me as I ensure I keep things backed up in multiple ways.

    However, I wonder if this will start to become a new type of data breach. Will officials of governments be required to relinquish their devices when proceeding through customs? Will this happen to corporate employees? Something like this happened and it was unclear if this was an action on the part of the Department of Homeland Security in relation to an investigation. However, could this start to become a standard practice as a way for governments to spy on other governments or even corporations?

    This definitely sounds like a movie plot more than something that occurs in real life I would guess this is what we’ll find to be true here. It’s also not likely to be that effective if it does become a standard practice. If devices were being confiscated and checked at any scale, I’m sure we’d all be looking to travel with blank laptops that only had a VPN connection. Once we crossed a border, we could easily access information and download it as needed, deleting it before we recross the border.

    However carrying information on a mobile device is always a bit risky. You could lose a device by accident or theft, and anything you had on the hardware could be exposed to others. For most of us, it’s not a problem, but since some of us carry around database backups or developemnt data, we should be sure that we aren’t carrying sensitive information. There’s really no excuse to do so, no matter what your deadline. Use masked sets of test data that you don’t mind losing, and you won’t have an issue.

    Steve Jones

    The Voice of the DBA Podcast

    Listen to the MP3 Audio ( 2.1MB) podcast or subscribe to the feed at iTunes and LibSyn.