sql query Archives - {coding}Sight https://codingsight.com/tag/sql-query/ Blog for SQL Server DBAs and Developers Sat, 12 Aug 2023 07:13:17 +0000 en-US hourly 1 https://wordpress.org/?v=6.5.2 https://codingsight.com/wp-content/uploads/2021/10/cropped-Soсial_-Fb_180х180-1-32x32.png sql query Archives - {coding}Sight https://codingsight.com/tag/sql-query/ 32 32 SQL Aggregate Functions: Easy Tips for Newbies https://codingsight.com/what-are-sql-aggregate-functions-easy-tips-for-newbies/ Wed, 28 Sep 2022 07:59:00 +0000 http://codingsight.com/?p=15123 SQL Aggregate Functions are functions that perform calculations and return a summarized result. With these, it’s easy to do these calculations on data sets: But there’s more. Statistical calculations like standard deviation and variance are also part of the tools. Mix it with grouping and sorting, and you’ll have something fantastic for your new report. So, …

The post SQL Aggregate Functions: Easy Tips for Newbies appeared first on {coding}Sight.

]]>
How to Write Complex Queries in SQL https://codingsight.com/how-to-write-complex-sql-queries/ Fri, 18 Jun 2021 08:42:24 +0000 http://codingsight.com/?p=14744 Typical queries in the SELECT * FROM table format are sometimes not enough. When the data for a query is not in one table, but in several, or when it is necessary to specify several selection parameters at once, you will need more sophisticated queries. This article will explain how to build such queries and …

The post How to Write Complex Queries in SQL appeared first on {coding}Sight.

]]>
Query Optimization Techniques in SQL Server: 5 Best Practices to Boost Queries Performance https://codingsight.com/sql-query-optimization-5-core-facts-to-boost-queries/ Wed, 31 Mar 2021 16:48:05 +0000 http://codingsight.com/?p=12665 What is query optimization in SQL Server? It’s a big topic. Each technique or problem needs a separate article to cover the bases. But when you’re just starting to level up your game with queries, you need something simpler to rely on. This is the goal of this article. You might say your queries are …

The post Query Optimization Techniques in SQL Server: 5 Best Practices to Boost Queries Performance appeared first on {coding}Sight.

]]>
9 Best Practices for Writing SQL Queries https://codingsight.com/sql-query-optimization-tips/ Mon, 29 Mar 2021 12:31:11 +0000 http://codingsight.com/?p=12647 If you are reading this article, most probably, you are already familiar with SQL. You know how to write basic SQL queries. There are many ways to execute a SQL query to get desired results on your database. However, not all SQL queries are created equal. Most can be optimized to follow the SQL query …

The post 9 Best Practices for Writing SQL Queries appeared first on {coding}Sight.

]]>
SQL Reference Table: How to Create and Write Basic Queries https://codingsight.com/writing-simple-sql-query-from-reference-table/ Tue, 02 Mar 2021 10:20:59 +0000 http://codingsight.com/?p=12306 This article will focus on writing SQL queries against the database reference table with a fairly simple structure to understand and implement. Additionally, we are going to clarify the concepts behind writing effective SQL queries along with some professional life tips. Before Querying the Database Tables As this article is about querying database tables with …

The post SQL Reference Table: How to Create and Write Basic Queries appeared first on {coding}Sight.

]]>
SQL Basic Commands: How to Write Simple Queries with Examples https://codingsight.com/how-to-write-simple-sql-queries-from-blank-database/ Thu, 25 Feb 2021 08:30:49 +0000 http://codingsight.com/?p=12213 This article explains writing simple SQL queries from the most basic ones and gradually improving the script to solve some mathematical and date-related problems. Additionally, we are going to clarify the concepts surrounding SQL queries. Although this article is primarily for beginners, it contains hints that will be helpful for any experience level. What is …

The post SQL Basic Commands: How to Write Simple Queries with Examples appeared first on {coding}Sight.

]]>
How CTE Can Aid In Writing Complex, Powerful Queries: A Performance Perspective https://codingsight.com/how-cte-can-aid-in-writing-complex-powerful-queries-performance-perspective/ Fri, 20 Nov 2020 12:49:37 +0000 https://codingsight.com/?p=10672 We often see poorly written complex SQL queries running against a table or tables in databases. Those queries make the time of execution very long and cause consuming huge CPU and other resources. Still, complex queries provide valuable information to the application/person running them in many cases. Therefore, they are useful assets in all varieties …

The post How CTE Can Aid In Writing Complex, Powerful Queries: A Performance Perspective appeared first on {coding}Sight.

]]>
The Easy Guide on How to Use Subqueries in SQL Server https://codingsight.com/the-easy-guide-on-how-to-use-subqueries-in-sql-server/ https://codingsight.com/the-easy-guide-on-how-to-use-subqueries-in-sql-server/#comments Tue, 28 Jul 2020 09:10:33 +0000 https://codingsight.com/?p=9587 Do you use SQL subqueries or avoid using them? Let’s say the chief credit and collections officer asks you to list down the names of people, their unpaid balances per month, and the current running balance and wants you to import this data array into Excel. The purpose is to analyze the data and come …

The post The Easy Guide on How to Use Subqueries in SQL Server appeared first on {coding}Sight.

]]>
https://codingsight.com/the-easy-guide-on-how-to-use-subqueries-in-sql-server/feed/ 1