Search Results prp_proposal_tokens




Overview

The PRP_PROPOSAL_TOKENS table is a core data repository within the Oracle E-Business Suite Proposals (PRP) module, specifically in versions 12.1.1 and 12.2.2. It functions as the storage mechanism for user-defined tokens and their associated values within the context of a specific proposal. Tokens are dynamic placeholders used to personalize proposal documents, correspondence, and other outputs. This table exclusively manages tokens defined by users that are of the "Text" or "List of Values" data types, distinguishing it from system-generated or other token types. Its primary role is to enable the dynamic substitution of token names with their actual values during proposal generation, ensuring content is tailored to the specific customer, opportunity, and proposal details.

Key Information Stored

The table's structure centers on linking a token to a proposal and storing its resolved value. The key columns include PROPOSAL_TOKEN_ID, which serves as the unique primary key for each token-value record. The PROPOSAL_ID column is a foreign key that ties the token value to a specific proposal header in the PRP_PROPOSALS table. The TOKEN_ID column references the definition of the token itself, which is stored elsewhere in the Proposals schema. Crucially, the table holds the actual VALUE for the token within the context of the given PROPOSAL_ID. This value is what replaces the token placeholder (e.g., `&CUSTOMER_NAME`) when a proposal document is published or a report is generated.

Common Use Cases and Queries

A primary use case is the generation of personalized proposal documents. When a user finalizes a proposal, the application queries this table to fetch all token values for that PROPOSAL_ID and performs a mass substitution in the document template. For reporting and data validation, administrators may run queries to audit token usage or troubleshoot missing values. A common SQL pattern involves joining to the proposal headers to see token values across multiple proposals:

  • Selecting all tokens for a specific proposal: SELECT token_id, value FROM prp_proposal_tokens WHERE proposal_id = <proposal_id>;
  • Listing proposals where a specific token has not been populated: SELECT p.proposal_number FROM prp_proposals p WHERE NOT EXISTS (SELECT 1 FROM prp_proposal_tokens t WHERE t.proposal_id = p.proposal_id AND t.token_id = <token_id>);

Related Objects

The PRP_PROPOSAL_TOKENS table maintains integral relationships with other core Proposals tables, as defined by its foreign key constraints. The most critical relationship is with the PRP_PROPOSALS table via the PROPOSAL_ID column. This ensures every token instance is scoped to a valid proposal. The table also references another table for the TOKEN_ID column, which based on standard Proposals schema knowledge is typically the PRP_TOKENS_B table that stores the master definition (name, type, description) of all available tokens. These relationships enforce data integrity, ensuring that token values cannot exist without a valid parent proposal and a valid token definition.