number of users based on roles

Hello

Is it possible to count the number of users assigned to a specific role?

Please share the SQL if they are available.

Kind regards

VN

First users are not assigned to a role. The users role. If you want to count how many users is granted directly special role:

Select count (*)

of dba_role_privs

where granted_role = 'PARTICULAR_ROLE_NAME. '

and dealer in)

Select the user name

from dba_users

)

/

Now the role can be granted to another role. So question don't you want to count the users who benefit indirectly particular role (e.g. another_role role is granted the particular_role role and the U1 user has an another_role and so indirectly benefits from the particular_role role)? If you do:

SELECT count (distinct dealer)

of dba_role_privs

where dealer in)

Select the user name

from dba_users

)

Start with granted_role = "PARTICULAR_ROLE_NAME".

connect granted_role = prior grantee

/

For example, the role R3 does not directly benefit any user, but is granted to the user scott indirectly-->-->--> SCOTT R1 R2 R3. First query will return 0 because it has roles with rights directly while the second query returns 1:

SQL > create role r1;

Created role.

SQL > create role r2;

Created role.

SQL > create role r3;

Created role.

SQL > grant r3 R2;

Grant succeeded.

SQL > grant r2 R1;

Grant succeeded.

SQL > grant r1 to scott;

Grant succeeded.

SQL > revoke scott r3;

Revoke succeeded.

SQL > revoke scott r2;

Revoke succeeded.

SQL > select count (*)
2 of dba_role_privs
3 where granted_role = "R3".
4 and beneficiary in)
5. Select username
6 of dba_users
7                     )
8.

COUNT (*)
----------
0

SQL > select count (distinct dealer)
2 of dba_role_privs
3 where dealer in)
4. Select username
5 of dba_users
6                     )
7 start with granted_role = "R3".
8 connect by prior grantee = granted_role
9.

COUNT (DISTINCTGRANTEE)
----------------------
1

SQL >

SY.

Tags: Database

Similar Questions

  • Several redirects URL after authentication of the user based on roles

    Hello
    I want to make several url redirects after login. It is:

    If a user connects to I want to open - 1.html.

    If user B logs I want open - 2.html.

    Please tell if this can be done in OAM or not and how do?

    First, create a simple policy area with Basic authentication scheme and test if you can you connect and see the home page of your application.

    Suppose you want to make redirects based on an attribute called user:
    myDepartment = IT, HR, finance, Support, HelpDesk
    Therefore, you should design 5 URLS for each of the departments above.

    Make sure that "myDepartment" is indexed in LDAP.

    The next step:
    Create a domain policy with the resources and rule rule & authentication check. Now, for the authorization, set the following:

    Authorization rules (5):
    AuthZ4IT, AuthZ4HR, AuthZ4Finance, AuthZ4Support, AuthZ4HelpDesk

    Definition of each:
    AuthZ4IT-> General:
    Enable wins: Yes
    AuthZ4IT-> Actions-> success of permission-> URL of Redirection:
    http://www.mycompany.com/it
    AuthZ4IT-> access-> rule:
    LDAP: / / / o = company, c = us? void? (myDepartment = IT)
    AuthZ4IT-> deny access-> role:
    Choose "any"

    Same for AuthZ4HR, AuthZ4Finance, AuthZ4Support, AuthZ4HelpDesk

    Expression of approval:
    AuthZ4IT or AuthZ4HR or AuthZ4Finance or AuthZ4Support or AuthZ4HelpDesk

    Now test the URL redirects.

    -shetty2k

  • Need your advice - the user name and roles

    We are the OEM deployment within our Organization.  There is a special requirement on business unit to have several names for the same person, with different roles.    Which means 'employee_1' will be 3 id for several roles such as employee_1_Administrator, employee_1_Operator, employee_1_Monitor!    Is - this recommended by Oracle? or it companies set up such a system? (I know it's technically feasible, but I'm confused as it is a best practice).

    Any suggestions or pointers are really appreciated.

    Vijay

    No, it sounds like a recipe for chaos for me I recommend several ROLES by user.  But if you have several users, they will constantly be logged in and out based on what targets that they manage and which kind of defeated the purpose of having a "Enterprise Manager" tool in my opinion.

    The way in which users EM are roles assigned, allows you to provide multiple roles functionality that can easily be revoked should change responsibilities.

    So create 3 roles:

    Administrator

    Operator

    Monitor

    Give the 3 roles employee_1

    I'd be interested to hear the conditions for this... but the only case that I heard in other companies is for a small number of people who have administrator-level privileges.  UserA was UserA account + userA_Admin.  Must not use their account "admin" for normal each daily tasks (management db, work planning, etc.) but only when necessary for higher level privileges.   Again, it is possible, but difficult.   Only 1 of about 40 clients that I worked with it.

  • even select (user name, profile, role, table_name, table privilege)

    Hello everyone

    1 - I don't know how to merge the two qys to refer to in the same setting (user name, profile, role, table_name, table privilege)

    IM using the dba_users users and sight of paintings: see next qry

    SELECT Nvl(US. IDUSUARIO, DELE DE.) USERNAME USER).
    US. DESCRIPCIÓN NAME,
    STATUS OF ACCOUNT_STATUS,
    OF THE. PROFILE
    CREATED FECHA_CREACION
    USERS.
    SYS. DBA_USERS OF
    WHERE THE. USERNAME IS US. IDUSUARIO (+)
    UNION
    SELECT Nvl(US. IDUSUARIO, DELE DE.) USERNAME USER).
    US. DESCRIPCIÓN NAME,
    STATUS OF ACCOUNT_STATUS,
    OF THE. PROFILE
    CREATED FECHA_CREACION
    USERS.
    SYS. DBA_USERS OF
    WHERE THE. USERNAME = UPPER (US IDUSUARIO)
    BY NAME;

    This snippet of me, USER, his TRUE NAME, STATUS, PROFILE, CREATION_DATE
    JP01 Johan Pena OPEN DEFAULT 07/05/2010

    -------------------------------------------------------
    On the other hand:
    ------------------------------------------------------
    Select * from role_tab_privs

    This extract me, ROLE, TABLE_NAME, and PRIVILEGE
    S/N SELECT TABLE1
    INSERT TABLE 1 DBA
    DELETE S/N TABLE2

    1 - I don't know how to merge the two qys to refer to in the same setting (user name, profile, role, table_name, table privilege)

    2 - I want something like that.

    USER, ITS TRUE NAME, STATUS, PROFILE, ROLE OF CREATION_DATE, TABLE_NAME PRIVILEGE
    JP01 Johan Pena DEFAULT OPEN 07/05/2010 DBA SELECT TABLE1
    JP01 Johan Pena, 07/05/2010 OPEN by DEFAULT DBA TABLE1 REMOVE

    ECT Ect. Ect.

    who can HELP me

    Hello

    Welcome to the forum!

    Whenever you have a question, please post CREATE TABLE and INSERT statements so people can recreate your example of table. (You don't have to post instructions CREATE TABLE to see themselves in the dictionary of data, such as ROLE_TAB_PRIVS, but do not post exactly what you see in these views).
    Anyway, after the accurate results of your choice in the sample data that you give.
    Without it, people will always try to help you as much as they can, but it probably won't be much.

    I don't know what you want. You want a result set with the same number of lines of output that your second request (the one with ROLE_TAB_PRIVS), but with all the data from the first query added to each line? If so, just cross join of two results. It will probably be easier if you make the UNION in a subquery, first:

    WITH     union_data     AS
    (
         SELECT      Nvl (US.IDUSUARIO,DU.USERNAME)      AS USUARIO,
         US.DESCRIPCION NAME,
         ...
         UNION
         SELECT      Nvl (US.IDUSUARIO,DU.USERNAME)      AS USUARIO,
         US.DESCRIPCION NAME,
         ...
         WHERE DU.USERNAME      = UPPER (US.IDUSUARIO)
    )
    SELECT     *
    FROM       union_data          u,
           role_tab_privs     r
    ORDER BY  u.name
    ;
    

    I suspect that you don't need really to a UNION, but it depends on your data and the exact results you want from these data.

    The result set will have u * traits r, where u is the number of rows in union_data, and r is the number of rows in the query based on tole_tab_privs.
    If you<=1, then="" order="" by="" clause="" will="" not="" actually="" do="">
    If you > 1, the results will make any sense?

  • How to get users to a role? BPM 11G.

    Hello everyone.

    I am in BPM 11 g and I would like to get all the users of a role, how can I achieve this?

    Thank you!

    Additional info:

    I use 11.1.1.6 Jdeveloper and SOA Suite 11.1.1.6.0

    Hello

    BPM has exposed all this security stuff to access progrmmatically in many ways:

    1. statement of the public to call in pure java classes API. Here is a class. You can find examples for this interface. Then you can call all methods, including your for users in a particular role (role of corridor JDeveloper BPM or defined in weblogic or level EM etc.)

    http://docs.Oracle.com/CD/E14571_01/apirefs.1111/e10660/Oracle/tip/PC/services/identity/BPMIdentityService.html

    2. Moreover, still based and Web based service interfaces are also exposed. Most of the APIs, functions can be tested using services Web using URL something like this:

    http://soahost:soaport / integration, services, IdentityService, identity

    http://docs.Oracle.com/CD/E16764_01/integration.1111/e10224/bp_workflow.htm

    I fell over the first url with my soahost and soaport. I chose the function list box named "getGranteesToAppRole). In the lower section, roleName, I gave my role as a corridor of JDeveloper (you can get EM or workspace as administrator too). For appId, enter "OracleBPMProcessRolesApp" as they are all of the ProcessRoles. Direct, enter false (means user can be in this role, or indirectly, we have group mapped to this role or direct user etc.). nomduroyaume can be empty, because for the most part we all use myrealm defaulty. Invoke hit and you get all the users in this role.

    3. Finally, all these presentations as XPath functions also. Open your JDeveloper and process diagram. Select all tasks or something so that you open XPath Editor. And in that you will see a lot of options as string fucntions, dates, logics and also identity Service. All methods are there for arguments just pass your payload data fields. This is useful if you need to get information saying as a manager of users connected to the process. Use the XPath method.

    4. Once you have explored API, firs try simple EJB. Then create a Wrapper for your EJB who has all the methods. and use this as adapater WebService or EJB adapter in the process also model.

    Thank you

    Ravi Jegga

  • Based on roles can read all the records

    Hello

    Could someone explain it as the field "based on roles can read all records" on ways to layout user?

    Thx a lot
    Jon.

    It is a new feature of visibility. It allows you to open the visibility all selectively. That is to say you can only allow users to view all Contacts and accounts but not all possibilities.

    Check out this webinar to support for more details.
    Record type based on visibility in functional presentation Analytics release 17 roles [ID 1052161.1]

  • Get the number of users connected to an access database

    Hello

    I want to develop a function that returns the number of users connected to an access database. I have CVI 2013 and the SQL Toolbox.

    Thanks in advance!

    ------------------------------------------------

    Hello

    I have a base on the network, and I wanted to develop a (CVI 2013 + SQL toolkit) function that returns me the number of users connected to this base.

    Thanks in advance!

    Thanks guys, unfortunately I have not found a SQL function that return the number of directly connected user. This is possible only on SQL Server.

    What I have is this: I created two fields in my database: a 'DB_is_used' flag and a "Username" field, and each user how want to use the database, should check these fields if it is empty, it inserts the name of its PC and use the database. Or, if the field is not empty, it will see a popup message displays the user name 'book' this database and the hedisconnect of him immediately.

    It works for me and I am satisfied.

    Kind regards

  • How to increase the number of user and a guest on laptop?

    By mistake I changed the number of user and it a how I could do so I odnt remember, but now I want to change new so that I can active comments as another user account, please let me know how to change a favor to active clients

    I now have Vista OS. before I could do guest account can be used but I dnt remember but somewhere I made a change which required the number of users on the desktop I have 1 now, I forgot

    to please tell me where this option, so I can do it again it 2 or 3 by the guest account now do either not connect you he says that this service is not available and cannot be connected

    Hi James,

    Maybe this will help:

    http://www.Vistax64.com/tutorials/93009-user-account-create.html

    http://www.Vistax64.com/tutorials/126933-guest-account-turn-off.html

    I hope this helps.

    Good luck!

  • Private Distribution list 25 maximum number of users

    On my system, users receive a message stating that they have added the maximum number of users to their distribution list private after the 25th Member via the TUI. The Administration of the unit guide indicates that there is not a limit on the number of users that can be added to a private Distribution list.

    Is there a limit of 25 reviews?

    This is a configurable parameter?

    Thanks in advance for any help!

    This is a bug in conversation - is taking over when we used to have to cram all members of the list in a binary blob and other things in an extended property to an Exchange 5.5 object back in the day - there have been forced space, so we had to limit the members of the DL.

    SA/APC removed this restriction everything at the time, but just UIS missed it - it is followed in this bug:

    http://www.Cisco.com/cgi-bin/support/Bugtool/onebug.pl?BugID=CSCed43179&submit=search

    Looks like the limit is fixed in version 4.0 (5) to come.

  • ASA VPN - allow user based on LDAP Group

    Hello friends

    I have create a configuration to allow connection based on LDAP Group.

    I m not specialize in the firewall and I tried to follow the links above, but both seem old, commanded several is not available.

    http://www.tunnelsup.com/Cisco-ASA-VPN-authorize-user-based-on-LDAP-group

    http://www.Cisco.com/c/en/us/support/docs/security/ASA-5500-x-series-NEX...

    Anyone know how I can do?

    Thank you

    Marcio

    I like to use the Protocol DAP (dynamic access policies) to control this.  Follow this guide:

    https://supportforums.Cisco.com/document/7691/ASA-8X-dynamic-access-policies-DAP-deployment-guide

  • Moving users to one role other than unauthenticated

    We deploy a NAC VGW OOB (4.7.2) solution and I working with the role of Unauthenticateed SSO.

    When I look at the users online, they are all:

    WindowsADServer Unauthenticated role

    But the function as I hope.

    I also have a role as an employee we have created as well as a consulting role.

    How I associated a user to a role? (Other than non-authenticated.)

    Also

    The access rule that I use for the role of the employee and consultant's role are identical.

    The only real difference is that the employee devices have a range more restricted opportunities for certification - which is an AV input and specific registry that identify him as an "active". Consulting the devices can use a broader set of AV and such.

    Rob,

    An authentication provider can be a role only. The caveat is that if you use the mapping rules and the help of LDAP attributes, you can then map to different roles then.

    More details about the Protocol LDAP Mapping here: http://tinyurl.com/2ex5uol

    HTH,

    Faisal

  • AnyConnect: User based authentication certificate filtering Configuration

    Hello colleagues in the network.

    recently I needed to configure AnyConnect SSL VPN with certificate authentication to meet the needs of connection at the request of the features of Cisco Jabber.

    Everything is ok, but I need to filter users based on their personal certificate information. For example - all those who have a personal certificate from our CA can now access this VPN. I want to set the users by e-mail of the certificate and only these users are granted access.

    I used this command:

    WebVPN

    allow outside

    AnyConnect image disk0:/anyconnect-win-3.1.04072-k9.pkg 1

    AnyConnect enable

    tunnel-group-list activate

    Certificate-Group-map Cert - filter 10 company-Jabber

    map of encryption ca Cert certificate - filter 10

    name of the object attr eq ea [email protected] / * /

    The problem is that I have to go can visit his profile - if I change [email protected] / * / to

    On the AnyConnect client - I connect to the GroupURL of the connection profile Company-Jabber

    Hi Alexandre

    There are several ways to approach this and this depends somewhat on the rest of the config, for example if you have other groups of tunnel etc..

    I guess the easiest way (if it does not interfere with the rest of your configuration) is to add something like this:

    crypto ca certificate map Cert-Filter 65535 subject-name ne ""

    This would attract all users/certificates does not not from your previous rules.

    Under webvpn you map these users to another tunnel-group (connection profile):

    certificate-group-map Cert-Filter 65535 NoAccess

    And configure the NoAccess group so that access is denied (for example, by setting simultaneous connections to 0 in the corresponding Group Policy).

    Other means would be to use DAP (dynamic access policies) to pretty much the same as the certmap, or permission to LDAP (for example retrieves the user name for the certificate, then perform an LDAP search to see if the user is allowed to use the VPN - in this scenario, there is no need to list all the users on the ASA but for example you need to create a new group on your LDAP server that contains all VPN users).

    Let me know if you want to go further in the foregoing

    see you soon

    Herbert

  • Maximum number of users Admin of Lobby on WISN

    / * Style definitions * / table. MsoNormalTable {mso-style-name : « Tabla normal » ; mso-tstyle-rowband-taille : 0 ; mso-tstyle-colband-taille : 0 ; mso-style-noshow:yes ; mso-style-priorité : 99 ; mso-style-qformat:yes ; mso-style-parent : » « ;" mso-rembourrage-alt : 0 cm 5.4pt cm 0 5.4pt ; mso-para-margin : 0 cm ; mso-para-marge-bottom : .0001pt ; mso-pagination : widow-orphelin ; police-taille : 11.0pt ; famille de police : « Calibri », « sans-serif » ; mso-ascii-font-family : Calibri ; mso-ascii-theme-font : minor-latin ; mso-fareast-font-family : « Times New Roman » ; mso-fareast-theme-font : minor-fareast ; mso-hansi-font-family : Calibri ; mso-hansi-theme-font : minor-latin ; mso-bidi-font-family : « Times New Roman » ; mso-bidi-theme-font : minor-bidi ;} Hello

    One of our clients we wonder on what is the maximum number of users Admin Lobby which could be created on a WISN? They are a University that might need around 60 users Admin of Lobby for their different faculties and administrative areas on campus.

    Thank you.

    Hello

    The maximum amount of guest accounts that can be created for the local user
    database is limited to a maximum of 2048 entries, default count is 512. This
    database is shared by local management users (including lobby ambassadors),
    net users (including guest users), MAC filter entries, and disabled clients.
    Together, as long as all of these types of users do not exceed the
    configured database size of 2048 you are ok.

    and

    http://www.Cisco.com/en/us/products/ps6366/products_tech_note09186a0080a49cd7.shtml#backinfo

    Thank you

    Serge

  • License AnyConnect SSL - increase in the number of users

    I have an ASA 5510 with SSL 100 users license. I'll add additional VPN users - how can I go on the increase in the number of authorized users? Can I buy a license 50 users and they will combine (to 150 users)? Or I have to jump up to 250 users?

    I contacted Cisco and got two different answers (see above). If anyone has a part number, it would be great.

    Thank you

    Greg

    Hi Greg -.

    The next bump in licensing for Anyconnect Essentials is the number of users of 250 max (L-ASA-AC-E-5510 =). If you run Anyconnect Premium is more gradual. Here are the part numbers and user account for Premium evasion.

  • SQL query to find the total number of source based nonsource passangersbetween source and destination station and passenger station on the same chekindate

    Hello

    SQL query to find the total number of source based nonsource passangersbetween source and destination station and passenger station on the same chekindate.

    Please help on this script and let me know if you need more details.

    ---

    You use a SELECT statement.  Let me know if you need more details.

Maybe you are looking for

  • CreateEvent() returns 0

    Hi all I use this code to call the CreateEvent function: It works very well, but not always. When I run for the first time, it returns the correct value non-zero. But when I call it a second time, the return value is 0. Then, qualifying for the third

  • Unwanted installation

    My laptop came with a program called Vongo I have not cared for and tried to uninstall. Somehow, I did something wrong, the file was deleted, but now whenever I start a windows session, it tries to install the Vongo program. It has no side effects, b

  • Trying to reinstall XP but get the message that I can't like exisiting version is newer.

    I am trying to reinstall XP (from CD) on my Dell Dimension 3000, but I get a message that the current version is newer and I need to boot with the CD. However, I can't figure out how to do this, because when I turn on the PC it starts automatically (

  • Monitor immediately goes into POWER SAVING MODE on startup

    Hello and HELP! Just unpacked a Dell Inspiron 530, I bought in January 2009 (long story). After all hang up, I turned it on. Monitor shows a brief moment, just a flash, AUTO DETECT (ANALOG INPUT) entering POWER SAVE, then it goes black and nothing th

  • Problem of Windows with Action Scripts run from a Panel

    I created a panel that has shortcuts for Menu items and tools. I have also two buttons on my slab that run scripts that were created with Actions. I tested these two scripts with the ExtendScript Toolkit for both Mac and windows.Both scripts do not r