Trim Left Char (for single words)
Remove the first replications of a specified char in a word. It does not work well with text that contains blank spaces in the middle.
2012-08-16 (first published: 2012-08-02)
955 reads
Remove the first replications of a specified char in a word. It does not work well with text that contains blank spaces in the middle.
2012-08-16 (first published: 2012-08-02)
955 reads
Generate a per-schema, per-procedure ordered list of all stored procedures for the current database, together with their parameters, datatypes and nullability.
2012-08-14 (first published: 2012-08-08)
2,251 reads
This helps to get list of all objects in a particular schemas.
2012-08-13 (first published: 2012-08-08)
1,158 reads
2012-08-13 (first published: 2012-07-31)
1,790 reads
Index Maintenance procedure with HTML Reporting capabilities. Please refer to attached script for detailed information.
2012-08-09 (first published: 2012-07-26)
1,662 reads
This simple function allows to calculate a code sequence of letters. AAA, AAB, AAAC, ADF, .... AAZ, ABA, ABC, ... ZZZ
2012-08-08 (first published: 2012-07-25)
956 reads
2012-08-03 (first published: 2008-01-09)
2,322 reads
2012-08-01 (first published: 2008-02-15)
3,219 reads
Identifies indexes with average logical fragmentation >= 30% using the DM available in MSSQL 2005. Please refer to script for more information.
2012-07-31 (first published: 2007-10-09)
4,376 reads
2012-07-25 (first published: 2012-07-12)
2,518 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