Blog Post

Searching dbatools–#SQLNewBlogger

,

Another post for me that is simple and hopefully serves as an example for people trying to get blogging as #SQLNewBloggers.

I learned something new about dbatools. That’s using the Find-DbaCommand cmdlet, which is handier than Get-Command. I’ll show you why in this post.

Searching PowerShell

You can search for commands with Get-Command. If I search for “key” in the dbatools module, I’d run this:

Get-Command *key* -Module dbatools

This returns me a number of items. In fact, it returns 11 items.

2021-11-20 11_56_58-C__Users_Steve (Admin)

That’s not bad, and this is how I’ve often been looking for command when I’m coding. This is faster than going to the index page on the site.

Find-DbaCommand

I was reading the upcoming dbatools in a Month of Lunches, and saw the Find-DbaCommand listed. If I use this, and include “key”, I get different results.

2021-11-20 11_59_14-C__Users_Steve (Admin)

This might be more than I want, but I thought this was a neat addition to the dbatools module to help someone find commands quickly.

It is definitely easier than going to dbatools.io and trying to search for a command in the command list.

SQLNewBlogger

I learned something, and I sketched out how to explain it to someone. I took 5 minutes to knock this post together. You could do the same thing, but expand on a way that you actually use this to find a command.

Might teach someone how a skill. Might even teach someone that wants to interview you.

Original post (opens in new tab)
View comments in original post (opens in new tab)

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating