PowerShell Basics

PowerShell
I'm just learning how to use PowerShell. I've been trying to spend time with it over the last year, ever since I saw Allen White's presentations at the PASS Summit last year. I just haven't had the time. But recently, my company has been performing a multi-phased data center move. Because of it, I've needed to run tests & updates, disable jobs, all kinds of things on different sets of servers on different days. To paraphrase the old Superman cartoons "This looks like a job <voice gets deeper> for PowerShell." I'm not even remotely qualified to begin teaching anyone PowerShell. I had problems recently getting an IF conditional statement to work correctly. However, in the interest of sharing, in case you're thinking about picking it up (do) or you're actively…
Read More

Help Make Connect Work Better

Misc
I've posted several times about how useful I find Microsoft Connect. I've seen issues introduced there get resolved through hot fixes and service packs. I sincerely believe it's a very important tool in your arsenal to get the kind of service you need from Microsoft. Here's a post on Connect that's trying to make Connect itself easier to use. I'd strongly recommend you swing by and vote positively for this. And for those who are unclear, click on the stars to submit your vote.
Read More

Database Screening Questions

SQL Server, T-SQL
With all the cool kids posting about beginners and interview questions, I thought I'd toss my favorites out there, from the brief-case gang point of view. These are the technical phone-screening questions I use after I look at a resume. There are only 10. They're simple. Stupid simple. Silly even. Yet, I can count on eliminating 4 out 5 people who have a resume that looks like a qualified DBA. I've seen people with 10 years experience fail on these questions. I'm only going to provide the questions. If you can't find the answers on your own, you're already disqualified: What is the difference between a clustered and non-clustered index? No, don't tell me that one is clustered and the other is not. I don't need specific low-level information on this, just…
Read More

Tim Ford’s Top 5 Indexing Best Practices

SQL Server, T-SQL
All I can really add to this is, yeah, me too. If you want some absolutely great advice on indexes, read this post. It's a must. And might I add, I've been the bad guy in Tim's example. Once, many, many years ago, I was reading from the SQL Server 7.0 documentation. It suggested that compound indexes were no longer needed since the optimizer could build them on the fly using index intersection. I had a performance problem and a consultant was telling me to use a compound index. I swore up and down it wouldn't work because Microsoft said so. He kept pushing and I kept pushing back. Finally, after a rather heated discussion in which I was convinced I had the upper hand, I got off the phone…
Read More

Unpacking the View

SQL Server, T-SQL
A view is simply a query that behaves something like a table. Most people know this. Most people also know that a view is simply a mask on top of what might be a very complex query. It all seems really simple. You call the view inside a simple query, the view runs the underlying complex query. Most people might not know that when a view is called and it gets sent to the optimizer, the optimizer unpacks the view and binds the component parts of the query necessary to create an execution plan that will return the data requested. What I didn't know until recently was that the optimizer is VERY smart. Not only does it unpack the query of the view, but it will change the query that…
Read More

Spatial Data

Spatial Data, T-SQL
I work for an insurance company. If you think that maybe, we might be interested in the physical location of the things we insure, you'd be right. Actually, we're an insurance company predicated on the idea that risk can be managed. That means that not only do we know where your factory is located. We know the wind zone, earthquake zone, flood zone, rain zone and temperature zone it's in. We send engineers out to the site to inspect it and recommend upgrades. We track the upgrades and the condition of your facility. With all that location specific information, just how important do you think it is that with SQL Server 2008 we're finally getting a spatial data type? Yeah, exactly. We're in the process of launching our first full implementation…
Read More

Pushing Connect

PASS
I have posted multiple times that I think Microsoft Connect is one of the best tools you can use to communicate with Microsoft. It works. Buck Woody is reinforcing my position from the Microsoft side of the fence. Look, Microsoft is not a small nimble company like Red Gate. And again, unlike Red Gate, you might not find yourself in a conversation with the CEO of Microsoft on the floor of a conference like the PASS Summit. And short of going to PASS or TechEd to track down some of the developers and project managers (many of whom attend these conferences), you need to have a mechanism to communicate with the company. You can try standing on your front door step and screaming (trust me, the neighbors just call the police)…
Read More

SQL Quiz Part 4

Misc
Thanks SQLBatman. It's not like I need to do work or something. Who has been a great leader in your career and what has made them a great leader? First, I need to define what I understand a leader to be and then I'll see if I have any great ones on the list. There are a lot of ways to define what a leader is. You could say simply the managers, team leads, CEO's and CIO's that you've worked for or with are leaders. But I don't see that. I think of a leader and I see Henry V and the St. Crispin's day speech, "...And gentlemen in England now-a-bed shall think themselves accurs'd they were not here, and hold their manhoods cheap whiles any speaks that fought with…
Read More

Publishing at PASS

PASS
I've been working with Andy Warren on several things for PASS through the editorial committee. Some of the work is available now. First, I've searched out all the online SQL Server communities that I could track down. I gathered information about the community and whether or not they published articles and what the contact for publication is. All the information about the online communities is gathered in one place. Please look them over. If I missed someone's favorite community, please let me know. I'll update it. If I've got some bad information up there, again, pass the word and I'll get the changes in. If you're looking for somewhere to go for help, support, or just someone to talk to, I think you can find something to suit you there. PASS is…
Read More