I will start this article with a real-life story, occurred to me. As a database consultant, I do a lot of different works. I write technical articles (apparently), but I also do some other database tasks like SQL development and database administration. So I have a lot of SQL clients and tools installed on my notebook. One sunny day I begin to work in the morning, while I enjoyed a coffee I opened my SQL client, and I run a simple script to create and populate a table for an article I was writing. As many of you probably do, before I create a table, I try a “drop table” using the “if exists” clause, just to be sure the “create table” works. The table name was an employee, a pretty common table name and you know what? I connected my SQL client default with a production database; I didn’t realize that (my fault). And of course, my client production database had a table called employee!!
At the same moment I press the green arrow to execute the SQL, I realized that something was wrong. I tried to revert but was too late, and the table employee of the production database of an important customer was deleted. Nice day!
Why I’m telling this history? Easy: because if my SQL client should have QuerySense, the table wasn’t be dropped.
The QuerySense feature makes TeamSQL unique. I worked with several SQL clients. QuerySense can detect any potential data destroy SQL like truncate, drop, or delete and display a box asking you for a confirmation, as you can see in the following print screen:
When QuerySense Works?
The QuerySense feature is activated by default on any production connection. Again we are talking about another big concept of TeamSQL: “production connections”, that is not minor, and believe it or not, is a concept not present in many modern SQL clients. Anyway if you want to activate the QuerySense feature on all the connections, you can do it by going to File menu, and then select the Preferences option. You can see the following window:
In the preferences window, you can activate QuerySense for all connections(production and non-production), or if you wish you can turn off QuerySense.
TeamSQL is a SQL client plenty of exciting features, some of them (like snippets, cloud queries, themes, or even the subject of this article: QuerySense) make TeamSQL a unique and modern piece of software. With the delivery of every new version of TeamSQL, we are powering a fast-growing community of users. Experiment TeamSQL and be a proud member of the TeamSQL community.