You can add data to a placeholder in many ways. The global viper method placeholder.add() accepts an id of the placeholder to add data to, and a variable number of parameters for the column values of a new row.
With help of a SQLQuery macro, a list of all items in the contents table is created. This list is grouped by contenttype. A Placeholder macro is used to create a container. This container is filled when formatting the rows of the sqlquery macro. The placeholder is formatted as a list of all contenttypes with the amount of items of that contenttype. This result is displayed as a list of hyperlinks with bookmarks, directing to the right place within the formatted result of the sqlquery macro.