April 26, 2020
Estimated Post Reading Time ~

Bulk Editor in AEM

The Bulk Editor allows for very efficient editing when the visual page context is not needed as it lets you:
search for (and display) content from multiple pages; this is done using GQL (Google Query Language)
edit this content directly in the bulk editor
save the changes (to the originating pages)
export this content to a tab-separated (.tsv) spreadsheet file

Goto Tools-> Importers -> Bulk Editor


How to Use the Bulk Editor
The bulk editor allows you to:
search for content based on query parameters, to display specified properties of the results in columns, to edit this content and save the changes
to export this content to a tab-separated spreadsheet
to import content from a tab-separated spreadshee

SEARCHING AND EDITING CONTENT
To use the bulk editor to edit multiple items simultaneously:
In the Tools console, click the Importers folder to expand it.
Double-click the Bulk Editor to open it.

Enter your selection requirements:
Field Property
Root Path Indicates the root path the bulk editor searches.
For example, /content/geometrixx/en. The bulk editor searches over all child nodes.
Query Parameters Using GQL parameters, enter the search string you want the bulk editor to look for in the repository; for example, type:Page looks for all pages in the root path, text:professional looks for all pages that have the word "professional" in them, and "jcr:title":English looks for all pages that have "English" as the title. You can only search for strings.
Content Mode check box Select this check box to read properties within the jcr:content sub node of the search results if exists. Use for pages only. Property names are prefixed with "jcr:content/"
Properties/Columns Select the check boxes for the properties that you want the bulk editor to return. The properties you select are the column heads in the results pane. By default, the node path is displayed in the results.
Custom Properties/Columns Enter any other properties that are not listed in the Properties/Columns field. These custom properties appear in the results pane. You can add multiple properties by using a comma to separate properties. Note: If you add a custom property that does not yet exist, CQ WCM displays an empty cell. When you modify the empty cell and save it, the property is added to the node. The newly created property must respect node type constraints and property namespaces.

For example:
Click Search. The Bulk Editor displays the results.
For the example above, all the pages that meet your search criteria are returned and displayed with the requested columns.

Make any changes you need by double-clicking in a cell.

Click Save to save your changes (the Save button will be activated once you have edited a cell).

Additional GQL Query Parameters
path: only search nodes below this path. If you specify more than one term with a path prefix, only the last one will be considered.
type: only return nodes of the given node types. This includes primary as well as mixin types. You may specify multiple comma separated node types. GQL will return nodes that are of any of the specified types.
order: order the result by the given properties. You may specify multiple comma separated property names. To order the result in descending order simply prefix the property name with a minus. E.g.: order:-name. Using a plus sign will return the result in ascending order, which is also the default.
limit: limits the number of results using an interval. E.g.: limit:10..20 Please note that the interval is zero based, start is inclusive and end is exclusive. You may also specify an open interval:limit:10.. or limit:..20 If the dots are omitted and only one value is specified GQL will return at most this number of results. E.g. limit:10 (will return the first 10 results)

EXPORTING CONTENT
You may need to export content and make changes to it in an Excel spreadsheet. For example, you may want to export a mailing list and change the area code of all the listed phone numbers directly in Excel, add additional lines, and so on.
To export content:

Search for content as described in Searching and Editing Content.
Click Export to export the changes into a tab-separated Excel spreadsheet. CQ WCM asks you where you want to download the file.

NOTE
By default, changes are encoded in Windows-1252 (also known as CP-1252). You can check UTF-8 to export the changes in UTF-8.

Select the location and confirm that you want to download the file.
After you download the file, you can open it from your spreadsheet program, for example, Microsoft Excel. The spreadsheet program imports the file and converts it to a spreadsheet format.

IMPORTING CONTENT
By default the import functionality is hidden when you open the Bulk Editor. Simply adding the parameter hib=false to the URL will display the Import button on the Bulk Editor page. You can import content from any tab-separated (.tsv) file. In order for importing to work properly, the column headings (first row of cells) must match the column headings of the table you are importing to.

NOTE
When you re-import content, you erase any previous content for those nodes. Be careful not to overwrite important information.

To import content:
Open the Bulk Editor.
Add ?hib=false to the URL, e.g.:
http://localhost:4502/etc/importers/bulkeditor.html?hib=false
Click Import.
Select the .tsv file. The data are imported into the repository.



By aem4beginner

No comments:

Post a Comment

If you have any doubts or questions, please let us know.