September 15, 2017 at 12:17 pm
Comments posted to this topic are about the item Avoiding the Hell of having to Remember DDL syntax
Best wishes,
Phil Factor
September 15, 2017 at 1:39 pm
What's your favorite way of keeping your productivity going strong without excessing 'googling?' I'd be fascinated to know.
There is a thing called 'excessive googling'? Ut oh.
September 15, 2017 at 1:59 pm
That AceText clipboard history tool sounds like a good place to keep common code blocks for things like error handling or DMV queries. Also, if you simply type the one or two word preamble of a DDL statement (like CREATE TABLE) into a SSMS query window, highlight it, and press the F1 key, it will automatically open the relevant MSDN topic in a web browser tab.
"Do not seek to follow in the footsteps of the wise. Instead, seek what they sought." - Matsuo Basho
September 15, 2017 at 3:16 pm
Cut/paste? :laugh:
I love Prompt, and every once in awhile I don't have it and my productivity goes down.
I've definitely enjoyed templates over the years, and often used them as snippets of code. Maybe using a common join pattern, like:
orders o
inner join orderlines ol
on o.orderid = ol.orderid
inner join products p
on ol.productid = p.productid
Of course, the parameters in SQL Prompt snippets, or templates, are a godsend. I've used those extensively, and often find myself creating a new one if there's certain code that I'm entering over and over where I see a pattern.
September 16, 2017 at 7:48 am
I use SQL Prompt for most everything. I have custom stuff in it to that I share with the team to keep us on the same page. It's really beneficial.
The only issue is I have fully migrated to Azure Data Warehouse and SQL Prompt does not fully support all of their specific statements. Thus, I commonly Google what I need there from the resource pages of Microsoft. This is not a big problem for me, but when I do use SQL Prompt formatting, which I commonly use, it invalidates the syntax that is correct with Azure and causes issue with syntax it can read.
They may have an update for this, but haven't checked lately.
September 18, 2017 at 12:43 pm
I use SQL Prompt too, but more for shortcuts (e.g. expanding SELECT *) rather than to remember how to do something in code.
I will use tab history (also from Redgate) to recall code I use regularly. I usually know the keyword to recall it and it saves me a trip to a search engine.
If it's a query I need to remember (e.g. how to join a set of tables together correctly), I usually just remember where such a query exists & start from that query next time. I don't spend time maintaining a separate library of snippets.
Other than that, I don't mind excessive searching. For a few things (the exact range of smallint for example), I know the search term and I recognize the page I trust to get the information from. And that way it works wherever I am - my productivity isn't going to go down the toilet on a new machine. At some point, after googling the same code snippet for a while, I remember what it is, and could likely do it from memory (if the internet was down for example). But, when the internet isn't down, I see no reason to put myself through that pain.
At the end of the day, I figure it's more important that I know something exists and know how to find it, than it is to memorize the exact syntax.
Leonard
Madison, WI
September 19, 2017 at 9:09 am
We keep our frequently use queries on a wiki
412-977-3526 call/text
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply