Easy Question: How to identify user roles within form?

Hi folks,
I would like to display/hide button which calls static data maintenance form (from other form) based on current user roles.
If user has role "STATIC_DATA" granted then DISPLAY button (which calls static data form), else DO NOT DISPLAY it.
Any example, how to get user roles within form?
Thanks,
Tomas

I can do it with below code:
declare
  l_cnt number;
begin
  select count(*)
     into l_cnt
     from user_role_privs
  where granted_role = 'STATIC_DATA';
  if l_cnt > 0 then
        -- display it
  else
     -- do not display
  end if;
end;I think, above should work.
Thanks,
Tomas

Similar Messages

  • I have 100 groups in planning for those 100 groups i want to build roles like interactive,view user,planner etc.for those how to change in export -import folder .xml file  in that edit  how  to change user roles in that xml it will generate automatic id.h

    I have 100 groups in planning for those 100 groups i want to build roles like interactive,view user,planner etc.for those how to change in export -import folder .xml file  in that edit  how  to change user roles in that xml it will generate automatic id.how to do that in xml file ?

    Thanks john for you are reply.
    I had tried what you sad.I open shared service in that foundation project i had export shared service.after that in import-export file.In that role.csv,user.csv,group.csv.Like this file have.When i open user file added some users after i trying save in excel it shown messgse
    I click yes and save the .csv file and import from share servie. i got error like this
    am i doing right way john.or explain clearly

  • BASIS query :how to transport user roles

    BASIS query :how to transport user roles
    regards
    Mave

    Hi Mave,
    Pls follow this
    Goto PFCG
    Enter the role there.
    On the application toolbar you can find the button for transport. Click on that and assign this to a transport request
    Release and transport to the other system.
    Cheers
    Vinod

  • How to identify which role user is associated with?

    Oracle 11.0.1.7:
    How do I identify which role a user is associated with?
    Also how do I identify the privilges for a given role. For eg if SELECT, INSERT, DELETE was granted for a table to a role which dictionary table do I look at?
    I looked at USER_TAB_PRIVS.

    Check this:
    http://www.adp-gmbh.ch/ora/misc/recursively_list_privilege.html
    HTH
    -Anantha

  • SSO and how to Managing User Roles/Privileges with Forms using Oracle db

    We are in the process of implementing Oracle Application Server SSO with our custom Forms application using Oracle database -- all 10.2.0.1.0 version.
    In our Forms Applications, we have about a dozen roles we have assigned to various users. We need to identify each user using our Forms because we are using the GLOBAL USER throughout the application.
    Questions:
    -- Do we have to create users/passwords in both OID and application database?
    -- Is there a way to easily manage the user and passwords between SSO and Forms App/database in one place? For example, how does a user change their password once, but actually change it in both the database and SSO?
    Any advice and/or direction would be greatly appreciated.
    Thank you,
    Mika
    Edited by: user11846198 on Sep 1, 2009 1:41 PM
    Edited by: user11846198 on Sep 1, 2009 1:53 PM

    Yes, you can have global roles in the DB and assign this roles to specific OID users, and the will heritage the privilages, you can do this using Oracle Identity Management Web Tool http://hostname:7777/oiddas is not complicated.
    Greetings.

  • Easy question - how to increase number of recent files in menu?

    This is for CS5 if it matters.
    I'm an infrequent Illustrator user (at best) but I have what I hope is an easy question: I want to increase number of recent files showing in the menu.
    I can't find a preferece to set such as in PS and almost every other application on the face of the earth. I've tried to reset the preferences file (start Illustrator with ctrl-alt-shift held down) but I'm stuck at 4 files, which I assume is the anemic default option.
    Is there an easy way to do this that Adobe has hidded somewhere? As expected, it can't be found in the help, I can't find it on the forums, or even on the net, but I do know it can be done because I can see other installs showing lots of files in the list.
    thanks for any help.

    This might be because of a new feature that you can turn off for each object, and alltogether. When you create a new document at the bottom, make sure 'Align New Objects to Pixel Grid' is unchecked.  After you have created a new file, you can still go into the 'TRANSFORM' palette (SHIFT+8), use the little right top menu, and make sure 'Align New Objects to Pixel Grid' is unchecked. And if you want to get fancy with each object; you can select an object, and look at the 'TRANSFORM' palette at the bottom is a place to uncheck the 'Align to Pixel Grid' at your disposall.
    Before I found this, it ruined my week.
    http://www.kenwells.com

  • ¿How to use user-roles in Ironport WSA (7.6) using ACS 4.1?

    Hello,
    I want to give a client access to a S370 WSA quarantine and I am using an ACS 4.1 for external authentication; that would be used for administrators and for the client access (non-administration access).
    I have created a user-role in the WSA that has access to the quarantine I want, but I need the user to be in the ACS. I created the user in ACS but my question is, what should I configure or change in the ACS in order for the WSA to recognize the user with the specific role I created and not like an administrator role.
    Thanks for your help!
    Sergio

    Hi,
    This can be done by configuring the Radius Class attribute on the ACS and mapping it with the user roles on the WSA.
    "To map RADIUS users to different Web Security appliance user role types, you assign a role type, such
    as Administrator and Operator, to a RADIUS CLASS attribute. Mapping different role types lets you
    specify the authorization level for each RADIUS user."
    Please go to Page 26-12 of the WSA user guide http://www.cisco.com/c/dam/en/us/td/docs/security/wsa/wsa7-5/user_guide/WSA_7-5-0_UserGuide.pdf for more information under the section "Using External Authentication".
    Regards,
    Kush

  • How to define user roles

    I am ready to deploy the form, but I want to define user roles.  How do I do that?

    You can't defines roles for the fillers. You can however define roles for the form design, responses data and summary reports by sharing the form. For more information see http://forums.adobe.com/docs/DOC-2462.
    Gen

  • How check the user roles in Business Partner edition screen?

    Hello Masters,
    I'm having a little problem figuring out how to check the user roles to allow modification in some fields.
    At the 'Manage Organizational Data' screen ('Manage Business Partners' -> Business Partner Data -> edit). I need to check the user roles to let him change the 'Tax Numbers' values. The values can be changed only if the user is a administrator; otherwise it must only show the value.
    I checked the HTML Template and found where I can restrict this edition option, but the problem is that I don't know how to check the user roles here. Maybe there is a function to do this?
    Any ideas of how I can do it? Is there any magical BAdI to check this?
    Thanks in advance,
    José Omar

    Hi José Omar,
    there is no BADI for this...
    You have to change the standard code to display only tax data if the SY-UNAME does not have correct role.
    You can retrieve user roles with BAPI_USER_GET_DETAIL, or access directly the activity groups table.
    Rgds
    Christophe

  • Easy Question: How to split concatenated string into multiple rows?

    Hi folks,
    this might be an easy question.
    How can I split a concatenated string into multiple rows using SQL query?
    INPUT:
    select 'AAA,BBB,CC,DDDD' as data from dualDelimiter = ','
    Expected output:
    data
    AAA
    BBB
    CCC
    DDDDI'm looking for something kind of "an opposite for 'sys_connect_by_path'" function.
    Thanks,
    Tomas

    Here is the SUBSTR/INSTR version of the solution:
    SQL> WITH test_data AS
      2  (
      3          SELECT ',' || 'AAA,BBB,CC,DDDD' || ',' AS DATA FROM DUAL
      4  )
      5  SELECT  SUBSTR
      6          (
      7                  DATA
      8          ,       INSTR
      9                  (
    10                          DATA
    11                  ,       ','
    12                  ,       1
    13                  ,       LEVEL
    14                  ) + 1
    15          ,       INSTR
    16                  (
    17                          DATA
    18                  ,       ','
    19                  ,       1
    20                  ,       LEVEL + 1
    21                  ) -
    22                  INSTR
    23                  (
    24                          DATA
    25                  ,       ','
    26                  ,       1
    27                  ,       LEVEL
    28                  ) - 1
    29          )       AS NEW_STRING
    30  FROM    test_data
    31  CONNECT BY LEVEL <= LENGTH(REGEXP_REPLACE(DATA,'[^,]','')) - 1
    32  /
    NEW_STRING
    AAA
    BBB
    CC
    DDDD

  • How to create Users/Roles for ldap in weblogic without using admin console

    Is it possible to create Users/Roles for ldap in weblogic without using admin console? if possible what are the files i need to modify in DefaultDomain?
    or is there any ant script for creating USers/Roles?
    Regards,
    Raghu.
    Edited by: user9942600 on Jul 2, 2009 1:00 AM
    Edited by: user9942600 on Jul 2, 2009 1:58 AM

    Hi..
    You can use wlst or jmx to perform all security config etc.. same as if it were perfomred from the admin console..
    .e.g. wlst create user
    ..after connecting to admin server
    serverConfig()
    cd("/SecurityConfiguration/your_domain_name/Realms/myrealm/AuthenticationProviders/DefaultAuthenticator")
    cmo.createUser("userName","Password","UserDesc")
    ..for adding/configuring a role
    cd("/SecurityConfiguration/your_domain_name/Realms/myrealm/RoleMappers/XACMLRoleMapper")
    cmo.createRole('','roleName', 'userName')
    ...see the mbean docs for all the different attributes, operations etc..
    ..Mark.

  • How to capture user ID within Calc script, when running?

    Client wants to capture run information automatically (user ID - who ran selected calc script ), and save that information in application itself to see who ran it last time, without checking related logs.
    User IDs have been enumerated already so if we can pick user ID text, we can set them as number value in Essbase. Expectation is to generate CDF to see related user ID and refer property file to get related number, to save in one of account. Its only possible if we can get in same session when run CDF and check who runs it.
    Any possible way to identify user ID from calc script in Essbase?
    Edited by: 962124 on Oct 15, 2012 9:30 AM

    Could you please mark the responses as helpful or answer so others can benefit from your time?
    Kyle Goodfriend
    http://www.in2hyperion.com
    Please make sure to assign helpful/answered to responses if applicable - it rewards those who help and benefits the user community.

  • Grant privileges, roles within Forms

    Hello,
    i have a forms application where each year can appear new users (e.g. employees), and i when a new employee appears i wanna grant him privileges, roles, etc within Forms. so is it possible having a form(accesible just for dba user) from where he can assign roles to another users ? (in employee table i have a column 'username'). also, when i insert a new employee, in post-insert query (i think) is it possible to have something like
    create user .... identified by ....... but here is a problem.. where can i write the password?
    Please clarify :)
    Regards,

    Roger22 wrote:
    but when i run the script how can i specify the password?what do you mean by specify the password? What's exactly your problem/requirement with specifying the pw?
    You can do this in forms using forms_ddl, but I'd use a database procedure for this which creates the user, does the granting stuff etc.
    e.g.:
    create or replace procedure createUser(ivUsername in varchar2) is
      cursor cGrants(cvUsername varchar2) is
        select 'grant '||decode(object_type, 'TABLE', 'select, insert, update, delete ', 'PROCEDURE', 'execute ', [...])|| ' to '||cvUserName as grant_stmt,
                 'create synonym '||object_name||' for '||cvUserName||'.'||object_name as syn
        from user_objects
        where object_name != 'CREATEUSER'
        and object_name not in (select synonym_name from all_synonyms where owner = upper(cvUserName);
    begin
      execute immediate 'create user '||ivUserName||'identified by '||ivUserName||' default tablespace my_tbs temporary tablespace my_temptbs quota unlimited on my_tbs';
      execute immediate 'grant connect, resource to '||ivUserName;
      for rGrants in cGrants(ivUsername) loop
        execute immediate rGrants.grant_stmt;
        execute immediate rGrants.syn;
      end loop;
    end;
    /A user with pw = username get's created (maybe you should provide your users a pw change functionality to change their passwords afterwards), he gets granted all the privilages to objects from the current user, and also synonyms get's created (if you want to use this the calling user should have the create any synonym privilage). Beware: If you want to do this you MUST NOT grant this procedure to the other users (so object_name != 'CREATEUSER') or use any other database procedures in it, as you'll get a lock when executing the grant statement and the procedure hangs.
    If you want to manage more schemas, you could create this procedure with the system user, modify the cursor to do a query on all_objects and restrict it to the schema from where you want to grant the privilages to (grant execute on schema.object to user), and pass the schema and the user to create to it.

  • How to find the "role" in forms 6i

    I need to find what roles does a user has from forms (roles such as "admin, reguser...etc...roles that i created"
    For example, i can find the following but i don't how to get the "roles"
    DECLARE
    UN VARCHAR2(80);
    PW VARCHAR2(80);
    CN VARCHAR2(80);
    BEGIN
    :global.UN := GET_APPLICATION_PROPERTY(USERNAME);
    :global.PW := GET_APPLICATION_PROPERTY(PASSWORD);
    :global.CN := GET_APPLICATION_PROPERTY(CONNECT_STRING);
    End;
    Thank you in advance.

    Hello,
    I made it in the following way:
    I have several roles that are granted to the user but
    are not default_roles. That means they must be enabled
    with the application.
    declare
    cursor c1 is select
    GRANTED_ROLE from user_role_privs
    where default_role = 'NO';
    rolen_name varchar2(30);
    rolen_alle varchar2(2000);
    i number := 0;
    BEGIN
    open c1;
    loop
         fetch c1 into rolen_name;
         exit when c1%NOTFOUND;
         i := i+1;
         if i = 1 then
         rolen_alle := rolen_alle || rolen_name;
         else
         rolen_alle := rolen_alle || ',' || rolen_name;
         end if;
    end loop;
    close c1;
    if i >= 1 then
    DBMS_SESSION.SET_ROLE(rolen_alle);
    end if;
    END;

  • Easy Question How to create Basic Groups and add respective Users

    Please help. I need to know how to create a basic group and later add users to the group. The group name would be callled Hardware and I will add johnsmith and janedoe to the group. Should I concern myself with the group id for whatever reason? I think the command is somthing like groupadd. Do I do somthing like:
    # groupadd Hardware
    # useradd -G Hardware johnsmith
    # useradd -G Hardware janedoe
    I'm using Solaris 10 if that helps.
    A million thanks I very New2Solaris,
    Johnny Mac

    Ok here is what I found on the net:
    change a user's group information change a user's primary group membership:
    usermod -g Hardware johnsmith
    usermod -g Hardware janedoe
    I forgot to mention that these are existing accounts (sorry)
    In order to change user's supplemental group membership:
    usermod -G Hardware johnsmith
    usermod -G Hardware janedoe
    is the supplemental group simply adding them to another group and not changing there primary group, which by default I think is staff. I would like to keep them in staff and add them to another group, in this case Hardware.
    Anyones thougths?

Maybe you are looking for