This discussion is archived
12 Replies Latest reply: Jun 16, 2007 11:17 AM by TimW RSS

CREATE A USER LIKE ANOTHER

user522961 Newbie
Currently Being Moderated
Hi,
how can I create an oracle applications USER exactly like another oracle applications user ?
Many thanks before.
  • 1. Re: CREATE A USER LIKE ANOTHER
    512041 Newbie
    Currently Being Moderated
    There is no copy user functionality available.

    you have to create your own program and do that using FND package

    Regards
    Prashant Pathak
  • 2. Re: CREATE A USER LIKE ANOTHER
    user522961 Newbie
    Currently Being Moderated
    Thank you. Do you sugest any FND package ?
  • 3. Re: CREATE A USER LIKE ANOTHER
    Hussein Sawwan-Oracle Employee ACE
    Currently Being Moderated
    FND_USER_PKG

    Note: 364898.1 - How To Update User Data Using a Supported API

    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=364898.1
  • 4. Re: CREATE A USER LIKE ANOTHER
    user522961 Newbie
    Currently Being Moderated
    Thank hsawwan, I found this :
    procedure CreateUser (
    x_user_name in varchar2,
    x_owner in varchar2,
    x_unencrypted_password in varchar2 default null,
    x_session_number in number default 0,
    x_start_date in date default sysdate,
    x_end_date in date default null,
    x_last_logon_date in date default null,
    x_description in varchar2 default null,
    x_password_date in date default null,
    x_password_accesses_left in number default null,
    x_password_lifespan_accesses in number default null,
    x_password_lifespan_days in number default null,
    x_employee_id in number default null,
    x_email_address in varchar2 default null,
    x_fax in varchar2 default null,
    x_customer_id in number default null,
    x_supplier_id in number default null)
    is
    dummy number;
    begin
    dummy := fnd_user_pkg.CreateUserId(
    x_user_name,
    x_owner,
    x_unencrypted_password,
    x_session_number,
    x_start_date,
    x_end_date,
    x_last_logon_date,
    x_description,
    x_password_date,
    x_password_accesses_left,
    x_password_lifespan_accesses,
    x_password_lifespan_days,
    x_employee_id,
    x_email_address,
    x_fax,
    x_customer_id,
    x_supplier_id);
    end CreateUser;

    in that package, but how to use it and how to use it for create like ?
    Many thanks.
  • 5. Re: CREATE A USER LIKE ANOTHER
    Fadi Hasweh Oracle ACE
    Currently Being Moderated
    can i ask yo a qusiton please, why do you need to create a user linked to another one.

    fadi
  • 6. Re: CREATE A USER LIKE ANOTHER
    user522961 Newbie
    Currently Being Moderated
    it is not linked but it is like.
    Because the functional staffs have asked to create some new users just like some others ancients users with the same responsabilities. But in OAM we did not see CREAT LIKE option. However it is available in OEM for oracle users.
    Regards.
  • 7. Re: CREATE A USER LIKE ANOTHER
    13808 Explorer
    Currently Being Moderated
    Maybe you what you need is AddResp(username varchar2,
    resp_app varchar2,
    resp_key varchar2,
    security_group varchar2,
    description varchar2,
    start_date date,
    end_date date) instead.

    General steps :

    1. CreateUser

    2. Use this query in cursor loop

    select d.product_code,b.responsibility_key from FND_USER_RESP_GROUPS_ALL a,fnd_responsibility b,fnd_user c,fnd_application d
    where a.user_id = c.user_id
    and a.responsibility_id = b.responsibility_id
    and b.application_id = d.application_id
    and c.user_name = <username you want to copy>

    3.and use FND_USER_PKG.AddResp

    4. end loop

    Hopefully it's clear enough.
  • 8. Re: CREATE A USER LIKE ANOTHER
    user522961 Newbie
    Currently Being Moderated
    Ok,
    thank you.
  • 9. Re: CREATE A USER LIKE ANOTHER
    561782 Newbie
    Currently Being Moderated
    Hi,

    We can use data loader programs to insert data in oracle forms (user creation forms). It will bring down the time needed for identical data insert.
  • 10. Re: CREATE A USER LIKE ANOTHER
    512041 Newbie
    Currently Being Moderated
    Data loader is useful when MASS load is required
  • 11. Re: CREATE A USER LIKE ANOTHER
    jpiwowar Journeyer
    Currently Being Moderated
    Just wanted to log a quick thank you to hsawwan and dgood76. I received a "can you help us add these 18 responsibilities to all of these 17 users, please?" request this week, and your pointers to the FND_USER_PKG API were very useful. Probably took as much time to write and debug my scripts as it would've taken to assign the responsibilities manually, but since we're likely to get more such requests over the life of our current project, we will certainly see an overall productivity savings in the group. :-)

    Cheers,

    John P.
  • 12. Re: CREATE A USER LIKE ANOTHER
    TimW Oracle ACE
    Currently Being Moderated
    You might also want to look at user management functionality. With user management you can create roles, which could be a series of responsibilities. You can then assign a role to a group of users and they will all get the same responsibilities.