Skip Headers

Oracle Assets User Guide
Release 12.1
Part Number E13586-04
Go to Table of Contents
Go to previous page
Go to next page

Oracle Assets Asset Description API

This appendix covers the following topics:


You can use this API if you have a custom interface that makes it difficult to use with the existing interfaces in Oracle Assets. The Asset Description API uses the FA_ASSET_DESC_PUB.UPDATE_DESC() procedure. You can use this API if you have a custom interface that makes it difficult to use with the existing interfaces in Oracle Assets. You can also update descriptions using the Asset Workbench.

Alternate Ledger Currency

If you have set up alternate ledger currency , when you add or modify assets using an Oracle Assets API, the API copies the transactions to the reporting currencies automatically. Invoice rounding issues are avoided by using the API to drive the alternate ledger currency accounting for both the ledger and reporting currencies.

Related Topics

Asset Description API Definition

Sample Script: Using the Asset Description API

Asset Description API Definition

The ASSET Description API procedure is called: FA_ASSET_DESC_PUB.UPDATE_DESC(). The following table provides the arguments, types, value, and descriptions of the elements of the FA_ASSET_DESC_PUB.UPDATE_DESC() procedure.

Each argument has a prefix of P, X, or PX. These prefixes mean the following:

Argument Type Value Description
P_API_VERSION NUMBER Internal use only Version of the API in use.
P_INIT_MSG_LIST VARCHAR2(1) FND_API.G_TRUE - Initialize the message stack FND_API.G_FALSE - Do not initialize the message stack (Default) Determines whether the messages stack should be initialized and cleared.
P_COMMIT VARCHAR2(1) FND_API.G_TRUE - Commit automatically.
FND_API.G_FALSE - Do not commit automatically (Default)
Commits the transaction.
P_VALIDATION_LEVEL NUMBER FND_API.G_VALID_ LEVEL_NONE - Lowest level of validation possible for a transaction FND_API.G_VALID_ LEVEL_FULL - Highest level of validation possible for a transaction (Default) Check on whether the API should validate the asset.
X_RETURN_STATUS VARCHAR2(1) FND_API.G_RET_STS_ SUCCESS - Transaction was a success FND_API.G_RET_STS_ ERROR - Transaction failed FND_API.G_RET_STS_ UNEXP_ERROR - Unexpected error Determines whether the API is successful.
X_MSG_COUNT NUMBER   Number of messages on the message stack.
X_MSG_DATA VARCHAR2(1024)   Message stack.
P_CALLING_FN VARCHAR2(30)   Function calling the API
PX_TRANS_REC FA_API_TYPES. TRANS_REC_TYPE   Describes the transaction taking place.
PX_ASSET_HDR_REC FA_API_TYPES. ASSET_HDR_REC_ TYPE   Unique identifiers for the assets.
PX_ASSET_CAT_REC_ NEW FA_API_TYPES. ASSET_CAT_REC_ TYPE   Category information of the asset.

TRANS_REC_TYPE Transaction Structure

The TRANS_REC_TYPE transaction structure contains information about the transaction, such as the transaction header ID and the transaction type code. The following table shows type and value information for each argument.

Argument Required / Optional Type Value
WHO_INFO Required STANDARD_ WHO_REC_ TYPE Standard Who Column

ASSET_HDR_REC_TYPE Asset Structure

The ASSET_HDR_REC_TYPE asset structure contains unique identification information for a given asset, such as the asset ID and book type code. The following table shows type and value information for each argument.

Argument Required / Optional Type Value
ASSET_ID Required NUMBER(15) OUT parameter
BOOK_TYPE_CODE Required VARCHAR2(15) Populate the book type code.


The ASSET_DESC_REC_TYPE asset structure contains descriptive information about the asset, such as the tag number, serial number, and manufacturer name. The following table shows type and value information for each argument.

Argument Required / Optional Type Value
ASSET_NUMBER Optional VARCHAR2(15) Defaults to the asset ID.
Optional OUT parameter.
DESCRIPTION Required VARCHAR2(80) Description of the asset.
TAG_NUMBER Optional VARCHAR2(15) User assigned tag number of asset.
SERIAL_NUMBER Optional VARCHAR2(35) Serial number of the asset.
ASSET_KEY_CCID Optional NUMBER(15) Identifies an asset key flexfield combination for the asset.
PARENT_ASSET_ID Optional NUMBER(15) Identifies a parent asset for subcomponents.
MANUFACTURER_NAME Optional VARCHAR2(30) Name of manufacturer.
MODEL_NUMBER Optional VARCHAR2(40) Model number of the asset.
WARRANTY_ID Optional NUMBER(15) Warranty identification number.
LEASE_ID Optional NUMBER(15) Lease identification number.
IN_USE_FLAG Optional VARCHAR2(3) YES - In use (default)
NO - Not in use
INVENTORIAL Optional VARCHAR2(3) Defaults to asset category.
YES - To include in physical inventory
NO - Do not include in physical inventory.
PROPERTY_TYPE_CODE Optional VARCHAR2(10) Defaults to asset category.
PROPERTY_1245_1250_CODE Optional VARCHAR2(4) 1245 - Personal
1250 - Real
Defaults to asset category.
OWNED_LEASED Optional VARCHAR2(15) OWNED - Owned (Default)
LEASED - Leased
Defaults to asset category.
NEW_USED Optional VARCHAR2(4) NEW - New (Default)
USED - Used
LEASE_DESC_FLEX Optional DESC_FLEX_ REC_TYPE Lease descriptive flexfield segments.
GLOBAL_DESC_FLEX Optional DESC_FLEX_ REC_TYPE Global descriptive flexfield segments.
COMMITMENT Optional VARCHAR2(150) Current financial burdens recorded against the asset, such as existing mortgages or pre-notices of mortgages.
INVESTMENT_LAW Optional VARCHAR2(150) Incentives available to businesses, depending on the region and the nature of the investor’s business. The current incentives are direct subsidy, interest subsidy, leasing subsidy, and tax exemption.

ASSET_CAT_REC_TYPE Asset Structure

The ASSET_CAT_REC_TYPE asset structure contains information about the asset category, such as the category ID and the category descriptive flexfield. The following table shows type and value information for each argument.

Argument Required / Optional Type Description
CATEGORY_DESC_FLEX Required DESC_FLEX_ REC_TYPE Category descriptive flexfield segments.

Sample Script: Using the Asset Description API

The following sample script shows how you can use the Asset Description API.

set serveroutput on;


   l_trans_rec                FA_API_TYPES.trans_rec_type;
   l_asset_hdr_rec            FA_API_TYPES.asset_hdr_rec_type;
   l_asset_desc_rec           FA_API_TYPES.asset_desc_rec_type;
   l_asset_cat_rec            FA_API_TYPES.asset_cat_rec_type;

   l_return_status            VARCHAR2(1);
   l_mesg_count               number;
   l_mesg                     varchar2(512);




   l_asset_hdr_rec.asset_id       := &asset_id
   l_asset_desc_rec.description   := '&description';
   l_asset_desc_rec.serial_number := '&serial_number';

           -- std parameters
           p_api_version             => 1.0,
           p_init_msg_list           => FND_API.G_FALSE,
           p_commit                  => FND_API.G_FALSE,
           p_validation_level        => FND_API.G_VALID_LEVEL_FULL,
           p_calling_fn              => null,
           x_return_status           => l_return_status,
           x_msg_count               => l_mesg_count,
           x_msg_data                => l_mesg,
           -- api parameters
           px_trans_rec              => l_trans_rec,
           px_asset_hdr_rec          => l_asset_hdr_rec,
           px_asset_desc_rec_new     => l_asset_desc_rec,
           px_asset_cat_rec_new      => l_asset_cat_rec);

   --dump messages
   l_mesg_count := fnd_msg_pub.count_msg;

   if l_mesg_count > 0 then

      l_mesg := chr(10) || substr(fnd_msg_pub.get
                                    (fnd_msg_pub.G_FIRST, fnd_api.G_FALSE),
                                     1, 250);

      for i in 1..(l_mesg_count - 1) loop
         l_mesg :=
                             fnd_api.G_FALSE), 1, 250);

      end loop;


   end if;

   if (l_return_status <> FND_API.G_RET_STS_SUCCESS) then
      dbms_output.put_line('ASSET_ID' || to_char(l_asset_hdr_rec.asset_id));
   end if;