aemjcr-sql2

AEM/CQ: UI for one-off JCR-SQL / SQL2 / XPath queries with tabular output?


I am doing a little usage research in our AEM installation. I would like to find all instances of a component and see what value they have for a certain configuration option. So basically, I want to select the title and myOption properties from all nodes with sling:resourceType myComponent.

I believe the JCR-SQL2 query would be:

SELECT [title], [myProperty] FROM [nt:base]
where [sling:resourceType] like 'path/to/my/component'

My problem is, I can't find a UI in which to run this query.

So my question is...

Is there another query UI buried somewhere in CQ that lets me put in one-off JCR-SQL / SQL2 / XPath queries with columns specified, and get a tabular output, the way you would with a SQL prompt or tool?

I would settle for a query builder incantation to produce pretty-printed JSON, so I could at least eyeball the JSON results.


Solution

  • You can use the bulk editor /etc/importers/bulkeditor.html . It is a great match for your requirement

    Just set root path as /content, uncheck content mode and for query parameters use "sling:resourceType":path/to/my/component. Set custom properties to title,myOption. It display's the result in a table.

    For more : http://docs.adobe.com/docs/en/cq/5-6/administering/bulk_editor.html

    Bulk editor only works for simple queries,for complex queries you can try this : http://adobe-consulting-services.github.io/acs-aem-tools/features/query-editor.html .