I may need to re-think the use of table variables
Table variables have been fixed in SQL 2019, so now I have to decide if I will use them again.
2024-07-26 (first published: 2018-12-11)
342 reads
Table variables have been fixed in SQL 2019, so now I have to decide if I will use them again.
2024-07-26 (first published: 2018-12-11)
342 reads
I recently changed jobs and my commute time doubled, I found myself with more time to think and I started asking questions.
2023-09-11 (first published: 2016-10-10)
234 reads
In today's guest editorial: the motivation to do our best must come from within.
2023-04-07 (first published: 2017-02-17)
209 reads
Is the stuff we do in our off hours truly relaxing or just taking up time?
2022-12-09 (first published: 2017-03-31)
208 reads
2022-09-26 (first published: 2018-03-16)
362 reads
Audit systems can be a good idea, but they can also be a mess to maintain.
2022-05-30 (first published: 2018-02-27)
307 reads
2022-05-16 (first published: 2018-01-15)
291 reads
Using a list to keep track of what you should work on is only as good as the plan or goal behind it.
2021-10-15 (first published: 2017-08-07)
234 reads
Today we have a guest editorial as Steve is traveling. Ben Kubicek notes that sometimes it is hard for technical people to communicate well.
2021-03-03 (first published: 2016-09-08)
206 reads
2021-01-19 (first published: 2018-01-23)
346 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