Which cardinality estimator (CE) was used in my query?
SQL Server 2008 is reaching end of support this year, so upgrading your SQL Server might be on your mind....
2019-02-25
590 reads
SQL Server 2008 is reaching end of support this year, so upgrading your SQL Server might be on your mind....
2019-02-25
590 reads
The series is alive! It’s been a while since I last talked about memory grants. Don’t worry, I still care...
2019-02-21
400 reads
I didn’t expect anything for free in index maintenance. After all, it takes a lot of CPU and transaction log...
2019-02-20 (first published: 2019-01-30)
2,424 reads
Yesterday’s post talked about single use plans. The statements I’m using are also called ad hoc queries. The alternative to...
2019-02-20
332 reads
So, we’ve set up a table with table partitioning on the RIGHT for CreationDate. We defined 11 partitions, and in...
2019-02-18
166 reads
Happy Friday! Today’s post will be light on the performance side and instead, I’m going to talk about how to...
2019-02-15
1,841 reads
This is the sequel to “It’s always parameter sniffing (part 1).” In that post, we identified the stored procedure, and...
2019-02-14 (first published: 2019-01-23)
2,519 reads
In Partitioning 1, my query searched through all 1-12 partitions. Let’s see if we can reduce that number.
Adding the partitioning...
2019-02-13
1,656 reads
This month’s T-SQL Tuesday is hosted by Andy Leonard at andyleonard.blog . Andy asks us, what is your “Why?”
So what is...
2019-02-12
686 reads
Proceed with caution, if you’re thinking of using query hints. This post will specifically cover min_grant_percent and max_grant_percent.
My opinion on...
2019-02-11 (first published: 2019-01-22)
10,131 reads
By Steve Jones
Redgate is a for-profit company. We look to make money by building and selling...
If you've ever loaded a 2 GB CSV into pandas just to run a...
By James Serra
What problem is Fabric Ontology trying to solve? For years, most data conversations have...
Comments posted to this topic are about the item The New Software Team
Comments posted to this topic are about the item Database Mail in SQL Server...
Comments posted to this topic are about the item The string_agg function
We create the following table and then insert some records in it:
create table t1 ( id int primary key, category char(1) not null, product varchar(50) ); insert into t1 values (1, 'A', 'Product 1'), (2, 'A', 'Product 2'), (3, 'A', 'Product 3'), (4, 'B', 'Product 4'), (5, 'B', 'Product 5');What happens if we execute the following query in both Sql Server and PostgreSQL?
select id,
category,
string_agg(product, ';')
over (partition by category order by id
rows between unbounded preceding and unbounded following) as stragg
from t1; See possible answers