2014-11-19 (first published: 2014-10-29)
1,137 reads
2014-11-19 (first published: 2014-10-29)
1,137 reads
This script will upload the latest backup files to an AWS S3 bucket
2014-11-14 (first published: 2014-09-14)
1,756 reads
List user connections and possibly any linked server connections older than 1 hour
2014-11-13 (first published: 2014-10-22)
1,697 reads
2014-11-11 (first published: 2014-07-25)
2,654 reads
2014-11-10 (first published: 2014-10-01)
1,357 reads
2014-11-06 (first published: 2014-09-02)
2,481 reads
2014-11-04 (first published: 2014-10-06)
1,372 reads
2014-10-29
1,184 reads
I am new to writing scripts so dont blast be to bad. This is a script to make all logins of a sql server readonly users to all user databases. Mainly after a restore from a different server. (for reporting maybe) Any methods to optimize this script are fine.
2014-10-27 (first published: 2004-04-14)
219 reads
This script has two essential Steps after restoring MSDB
2014-10-27 (first published: 2010-09-20)
2,331 reads
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...
By Steve Jones
Recently I ran across some code that used a lot of QUOTENAME() calls. A...
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