JCR-SQL2
1)Get global collections
SELECT * FROM [nt:unstructured] WHERE [sling:resourceType] = 'dam/collection'
2) Get Project specific collections
SELECT * FROM [nt:unstructured] WHERE [sling:resourceType] = 'cq/gui/components/projects/admin/card/projectcard' and NAME() = '150609_belk_fisharmvntbb';
3) Get nodes (DAM Assets) with specified name
SELECT * FROM [dam:Asset] where NAME([dam:Asset]) = 'one.indd'
4) Get nodes (DAM Assets) with specified name, order by path
SELECT * FROM [dam:Asset] where NAME([dam:Asset]) = 'one.indd' ORDER BY 'jcr:path'
5) Get nodes (DAM Assets) with specified name, order by last modified date descending
SELECT * FROM [dam:Asset] where NAME([dam:Asset]) = 'one.indd' ORDER BY 'jcr:content/jcr:lastModified' desc