How does Vertica generate columns such as all_roles ?

Looking at the underlying definition for v_catalog.users, there are a few columns such as all_roles, default_roles, and search_path which generate a concatenated list of their respective data.

I was unable to find these columns in vs_columns which leads me to the question of how are these columns generated since there's no native group concatenation functionality?

I'm aware of Concatenate.cpp.

Comments

  • v_catalog tables are built from the catalog itself. So, those fields are being combined from the catalog, not from other tables.
  • Dare I ask how, and how can this functionality be extended to work like a GROUP_CONCAT() function?
  • I assume it's done via code internally.

    You don't need group_concat to do pivoting, at least given a finite set of pivots, one could just do self-table joins. Though, that's not necessarily ideal, obviously.

  • Hi ,
    Both of the columns come from v_internal.vs_users.
  • That's not really helpful. My question is around the functionality to build the list.

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file