Defining user profiles

Written by Lucy / on 07/31/2009 / 2 Comments

Categories: Technical

We all know the we can refer system profiles by using FND_PROFILE.VALUE(profile_name). There are already existing system profiles. We can also define and set up profiles not provided by Oracle, for example: FTP_TO_TARGET_SERVER_NAME. In this case, we can refer it in PL/SQL by FND_PROFILE.VALUE('FTP_TO_TARGET_SERVER_NAME'). The below are the steps to define user profiles.

1) Log in as Application Developer responsibility, click on ‘Profile' from menu. when the form opened, input all necessary information.

Name: FTP_TO_TARGET_SERVER_NAME

Application: XX

User Profile Name: Target Server Name for FTP

Hierarchy Type: Security

Hierarchy Type Access Level: Check site and Application.

2) Switch to System Administrator responsibility

Menu: Profile -> System

Search for Profile: Target%FTP% on site level, the defined profile will be showed in the opened ‘System Profile Values' Window. (‘Profile Option Name' will be ‘User Profile Name ‘defined in step 1).

3) Set up the value for this profile in this window, then you can refer it by using FND_PROFILE.VALUE('FTP_TO_TARGET_SERVER_NAME').

Note: FND_PROFILE.VALUE(Target Server Name for FTP'). To avoid confusion, you can give the same name for Name and User Profile Name is step one.

This voids us to hard code the server path in the code. We can set up the different values in test and production environment without code change.

 

RSS Feed for this Blog    Comments Feed for this Post   

Comments

  • Ashalata says:

    Can you please provide the PL/sql code that references FND_PROFILE.VALUE.

    August 3, 2009 at 9:01 AM | Permalink

  • Lucy says:

    See below part of the code

    l_conn := ftp.login(FND_PROFILE.VALUE('FTP_TO_TARGET_SERVER_NAME'), '23', FND_PROFILE.VALUE('FTP_SERVER_USERNAME'),FND_PROFILE.VALUE('FTP_SERVER_PASSWORD'));

    ftp.put(p_conn => l_conn,
    p_from_dir => l_out_dir,
    p_from_file => l_out_file,
    p_to_file => l_to_file );

    ftp.logout(l_conn);

    August 3, 2009 at 11:12 AM | Permalink

 

Join this Group Now!

Forgot Password?