One of the new Extended Event available in SQL Server 2022 is the query_antipattern. This extended event allows to identify anti-patterns on the SQL queries sent to the server. An anti-pattern in this case is some code that the SQL Server optimizer can’t do a great job optimizing the code (but cannot correct the … Read more
A student of mine sent me a T-SQL challenge involving gap-filling of missing dates and balances. I found the challenge interesting and common enough and figured that my readers would probably find it interesting to work on as well. I’ll present the challenge and three possible solutions, as well as the results of a performance … Read more
Congratulations! You got the promotion!! Once the excitement and adrenaline rush of a promotion passes, it is common to find yourself staring at the yawning abyss of the unknown. Then you ask yourself the question that we all ask: “Now what?“ Do you know what upper management expects? Do you know where to start? Do … Read more
This article is based on exciting information just released at Microsoft’s Build conference on May 23, 2023. What we have today When Synapse Analytics was created, technical sessions inspired me with some comparisons and explanations, and I reproduced them in my own technical sessions and writing. Synapse was created from a request from many Microsoft … Read more
Welcome back to the MySQL optimization series! In case you haven’t been following this series, in the past couple of articles we have discussed the basics of query optimization, and told you how to optimize SELECT queries for performance as well. In this blog, we’re further learning ways to optimize INSERT operations and look at … Read more
In the first two articles of this series about PostgreSQL privileges, we reviewed how to create roles, grant them privileges to database objects, and how object ownership is an important aspect in managing access and control within the database. When it comes to managing what roles can access or modify an existing object, ownership is … Read more
When I first saw a bullet item stating SQL Server 2022 would support instant file initialization for log file growth, I was excited. When I later learned it only applies to automatic growths, and only those of 64 MB or less, I was a little less excited. With those limitations, I was skeptical this enhancement … Read more
Welcome to the second blog of the “magic of parameters” series. In the first entry, I covered memory parameters, and in this article. In this article will talk about PostgreSQL configuration parameters which manage the (auto)vacuum and (auto)analyze background processes. Why vacuuming is necessary? Before we start talking about vacuum and analyze-related parameters, we need … Read more
I was working for Xerox when the Xerox Star, precursor to all the computer systems in use today, was introduced. Before then, computer users just had command-line or character-based GUIs. The Xerox Star workstations were displayed for the first time for us insiders in a special room, like a secular chapel, guarded over by the … Read more
Database and development teams often load data from plain text files into their MySQL databases. The files might be used to add lookup data, support test and development environments, populate new MySQL instances, load data from regular feeds, or in other ways support their operations. To help with the import process, MySQL provides the LOAD … Read more
Having access to the psql command-line tool is essential for any developers or DBAs that are actively working with and connecting to PostgreSQL databases. In our first article, we discussed the brief history of psql and demonstrated how to install it on your platform of choice and connect to a PostgreSQL database. In this article … Read more
If you have been in the DevOps space, you should know about version control and must have worked with 0ne. But, have you heard of BitBucket? No? Well, this tutorial is for you. Bitbucket is a web-based platform that provides hosting services for version control repositories, specifically for source code and development projects. It offers … Read more
PostgreSQL has a separate command-line tool that’s been available for decades and is included with any installation of PostgreSQL. Many long-term PostgreSQL users, developers, and administrators rely on psql to help them quickly connect to databases, examine the schema, and execute SQL queries. Knowing how to install and use basic psql commands is an essential … Read more
I use Chat-GPT occasionally, instead of Google, to get answers to technical questions. Well there is definite value in promise in the technology, the trouble is that it currently uses authoritative sources with the same eagerness as blog posts written by newly-trained wannabe database devs who seek to get their names known, and I have … Read more
Cross-Site Request Forgery (CSRF) attacks are widespread, and even some BigTech companies suffer from them. Netflix suffered in 2006 with CSRF vulnerabilities. Attackers could change login credentials, change the shipping address and send DVDs to a newly set address. YouTube suffered from CSRF attacks where an attacker could perform actions of any user ING Direct … Read more
An important aspect of building and managing a database is organizing the objects within your database. You may have tables that support different functions, for example, a schema for warehousing operations and another for sales. Some logins may need access to some tables, but not others. You might want to isolate one set of objects … Read more
One of the more challenging technical details of columnstore indexes that regularly gets attention is the need for data to be ordered to allow for segment elimination. In a non-clustered columnstore index, data order is automatically applied based on the order of the underlying rowstore data. In a clustered columnstore index, though, data order is … Read more
In the previous article in this series, I introduced you to how to access MySQL data from within a Python script. The article described how to use the MySQL Connector to establish a connection with a database and then retrieve data through that connection. In this article, I continue the discussion by demonstrating how to … Read more
I have come across a lot of use cases for manufacturing rows on the fly, aside from the common goal of populating a large data set such as a numbers or calendar table. A few favorites include building sample data, pivoting an unknown number of columns, data extrapolation, and filling gaps in date or time … Read more