Converting values into Rows
Script describe one of the way to divide values into rows by using any specified dividing value.
2016-11-15 (first published: 2016-11-04)
832 reads
Script describe one of the way to divide values into rows by using any specified dividing value.
2016-11-15 (first published: 2016-11-04)
832 reads
2016-11-14 (first published: 2016-11-06)
708 reads
The function (Inline function) is used to determine the word count in a textual/string input.
* Compatible from SQL Server 2012 and up.
2016-11-11 (first published: 2016-11-04)
488 reads
if you get bunch of back up files ( full backup and transaction log backup, you need restore those database to different server, you can use my stored procedure to genereate the restore command
2016-11-10 (first published: 2014-12-17)
2,551 reads
This script will build restore scripts with the most recent full backup and all t-log backups since, for each user database in the SQL instance.
2016-11-09 (first published: 2016-11-01)
1,366 reads
You can monitor your web application by given its url and by creating the job in sql server 2005 which will send you the mail when ever your website is down.
2016-11-07 (first published: 2009-06-17)
11,944 reads
2016-11-03 (first published: 2014-10-07)
2,613 reads
This Script Generates A script to Create all Logins, Server Roles, DB Users and DB roles on a SQL Server.
2016-11-02 (first published: 2013-10-31)
33,147 reads
Add 3 columns, duration in seconds,Pagecount and fragmentation. For people like me who don't enjoy querying XML.
2016-10-31 (first published: 2015-11-12)
3,339 reads
Using OVER clause with ROW_NUMBER() function to get top ranked employee detail as per each department.
2016-10-25 (first published: 2016-10-03)
777 reads
By Steve Jones
Redgate is a for-profit company. We look to make money by building and selling...
I’ve uploaded the slides for my Techorama session Microsoft Fabric for Dummies and my...
If you've ever loaded a 2 GB CSV into pandas just to run a...
Comments posted to this topic are about the item Even When You Know What...
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...
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