Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-6918

Create a way to see a user's default role

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 10.1.3
    • Component/s: Admin statements
    • Labels:
      None

      Description

      There is currently no way to see a user's default role besides querying the mysql.user table

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            cvicentiu Vicentiu Ciorbaru added a comment -

            After discussing with Sergei and Elena, we have decided to go with the addition of an extra column within INFORMATION_SCHEMA.APPLICABLE_ROLES. The column will be named IS_DEFAULT and feature a YES/NO value accordingly. The information within the INFORMATION_SCHEMA.APPLICABLE_ROLES matches well with this request.

            Other possible approaches:

            • A function to give the default role for the current user. This would require more parameters to work for other users except the current one.
            • Modifying show grants to add an extra line there pointing to the default role. This is not 100% related to privileges so it does not match as good as adding the information within INFORMATION_SCHEMA.
            • Separate syntax show default role for [user]. This seems to add unnecessary complexity to the grammar.
            • Adding an extra variable. Users might try to set it, not considering it read only.
            Show
            cvicentiu Vicentiu Ciorbaru added a comment - After discussing with Sergei and Elena, we have decided to go with the addition of an extra column within INFORMATION_SCHEMA.APPLICABLE_ROLES. The column will be named IS_DEFAULT and feature a YES/NO value accordingly. The information within the INFORMATION_SCHEMA.APPLICABLE_ROLES matches well with this request. Other possible approaches: A function to give the default role for the current user. This would require more parameters to work for other users except the current one. Modifying show grants to add an extra line there pointing to the default role. This is not 100% related to privileges so it does not match as good as adding the information within INFORMATION_SCHEMA. Separate syntax show default role for [user] . This seems to add unnecessary complexity to the grammar. Adding an extra variable. Users might try to set it, not considering it read only.

              People

              • Assignee:
                cvicentiu Vicentiu Ciorbaru
                Reporter:
                greenman Ian Gilfillan
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 hour, 10 minutes
                  1h 10m