How to Avoid N+1 Queries: Comprehensive Guide and Python Code Examples
This article describes the N+1 problem that we often find when developers use row by row solutions for querying related data in a database.
2023-06-21
4,954 reads
This article describes the N+1 problem that we often find when developers use row by row solutions for querying related data in a database.
2023-06-21
4,954 reads
Learn how to use the Plotly library to visualize time series data in Python in this step-by-step article.
2023-06-16
Introduction In this article, we will learn how to generate images with AI. This time we will work with DALL·E. DALL·E is an image generator using AI. You just need to provide a description and DALL·E will generate the image: In this article we will learn these topics: First, we will learn what is DALL·E […]
2023-05-22
4,039 reads
This Python 3 script is designed to take CSV file data pasted into the csv_data variable and generate SQL insert statements that can be used to insert the data into a MySQL database. The script is easy to use and can save you a lot of time when working with large amounts of data.
2023-05-08 (first published: 2023-05-05)
5,935 reads
We may need to share our Python desktop or console applications with business users or deploy these applications to multiple machines. However, there are some challenges in the delivery of Python applications.
2023-04-24
Python has the ability to create many different types of charts and graphs and in this article, we look at how to create animated line plots with Python.
2023-03-03
This tip illustrates graphical and statistical tec...
2023-02-13
2023-02-06 (first published: 2023-01-18)
454 reads
Learn how to consume multiple API calls to load data to a SQL Server database using Python.
2022-10-17
Learn how to use Python code with Azure Data Studio to work with SQL Server data.
2022-10-03
14,471 reads
By Steve Jones
I caught this interesting item over on Pinal Dave’s blog: Eleven Interview Questions that...
By Hemantgiri
I use color-coded connections in SSMS to distinguish Production, Pre-Production, UAT, and Development. But...
Comments posted to this topic are about the item Split Large Queries in Athena...
Comments posted to this topic are about the item Finding Trailing Spaces
I have some data in a SQL Server 2025 database. It looks like this for the dbo.Customer table:
CustomerID CustomerName PreferredName 1 Steve Steve 2 Andy Andy 3 Brian Brian 4 Allan Allan 5 Devin Devin 6 Steve Steve 7 Sally SallyI want to detect which names have a single trailing space. The CustomerName is a varchar() and the PreferredName is a CHAR(). Does this query detect the problem rows?
SELECT
CustomerID,
CustomerName,
PreferredName
FROM Customer
WHERE CustomerName <> RTRIM(CustomerName)
OR PreferredName <> RTRIM(PreferredName); See possible answers