The PresentationTable name=Facts Revenue object must be updated to

12-12 Oracle Fusion Middleware Integrators Guide for Oracle Business Intelligence Enterprise Edition ConnectionPool DECLARE Repository 10. After you create the patch, your test repository might continue to change, including name changes that could affect the parentNames or other attributes in your patch code. If this occurs, regenerate the patch using the steps in this section. 11. You can use biserverxmlexec to execute the generated XML patch file against the test version of the repository to programmatically update the connection pool settings. For example: biserverxmlexec -I SampleApp_diff.xml -B SampleApp_test.rpd -O SampleApp_prod.rpd Give password: my_rpd_password To execute the XML patch file against a repository loaded into the Oracle BI Server, use biserverxmlcli.

12.3.6 Using XSL to Transform XML Files

You can use XSL to perform transformations on the XML files you generate. For example, you might want to use XSL to remove object IDs or UIDs to avoid conflicts. Example 12–2 shows a sample XSL script that you can use as a model for your own transformations. The example script disables all logical table sources in the repository. Example 12–2 Sample XSL Script ?xml version=1.0 encoding=UTF-8? xsl:stylesheet xmlns:xsl=http:www.w3.org1999XSLTransform version=2.0 xmlns:xalan=http:xml.apache.orgxslt xmlns:fn=http:www.w3.org200311xpath-functions xsl:output method=xml version=1.0 encoding=UTF-8 indent=yes cdata-section-elements=Description Expr Value xalan:indent-amount=4 xsl:strip-space elements= xsl:template match=RepositoryDECLARE xsl:element name=Repository xsl:element name=DECLARE xsl:for-each select=. xsl:call-template name=objectmatch xsl:for-each xsl:element xsl:element xsl:template -- The objectmatch template is matched for every metadata object -- xsl:template name=objectmatch xsl:choose -- We copy every object except for Logical Table Sources. We call the ltsmatch template for LTSs -- xsl:when test=name = LogicalTableSource xsl:call-template name=ltsmatch xsl:when xsl:otherwise xsl:copy-of select=. xsl:apply-templates xsl:copy-of xsl:otherwise About the Oracle BI Server XML API 12-13 xsl:choose xsl:template -- The ltsmatch template gets matched for every logical table source. -- xsl:template name=ltsmatch xsl:element name=LogicalTableSource xsl:for-each select=. -- We call the ltspropmatch template to process specific attributes on the LTS -- xsl:call-template name=ltspropmatch xsl:for-each xsl:for-each select=. xsl:call-template name=objectmatch xsl:for-each xsl:element xsl:template xsl:template name=ltspropmatch xsl:choose -- When we encounter the isActive property, we set it to false. -- xsl:when test=name = isActive xsl:attribute name=isActive xsl:textfalsexsl:text xsl:attribute xsl:when xsl:otherwise xsl:copy-of select=. xsl:apply-templates xsl:copy-of xsl:otherwise xsl:choose xsl:template xsl:stylesheet

12.4 Generic XML Elements and Attributes

This section describes generic elements and attributes that are common, like Description, name, and id. In the Oracle BI Server XML schema .xsd file, these elements and attributes are defined under the object_t and ref_t elements. The only common element is the Description element. This element can hold a text string describing a particular object. For example: Description [CDATA[ Generated by Time Series Wizard ]] Description There are eleven common attributes defined under the object_t element. Table 12–1 lists these attributes. Table 12–1 Common XML Attributes in object_t Attribute Name Description name The name of the object. parentName The qualified name of the parent of the object, in the format parent1.parent2.parent3, and so on. parentId The global unique identifier of the parent of the object, in the format type_id:parent_object_id. 12-14 Oracle Fusion Middleware Integrators Guide for Oracle Business Intelligence Enterprise Edition In addition to the common attributes defined in object_t, additional common attributes are defined in ref_t. These attributes are used when one object references another object or set of objects. For example, business model objects reference the logical tables contained in that business model, using the sub-element RefLogicalTable. All referenced sub-elements have the same common attributes shown in Table 12–2 .

12.4.1 About Object Identifiers

Oracle BI Server XML metadata objects can have three different types of object identifiers, any of which can be used to reference the object. Object identifiers include: ■ Fully qualified name qualifiedName. This identifier is the only reference you need to include in your XML when creating a new object, because the other identifiers uid and id are automatically generated by the Oracle BI Server when it opens the RPD file. The fully qualified name must be unique within the file, but the name the text after the last dot only needs to be unique within the scope of its parent. parentUid The internal identifier of the parent of the object. Referring to objects using this attribute instead of qualified names can provide faster access. id The global unique identifier of the object, in the format type_ id :object_id. uid The internal identifier of the object. Referring to objects using this attribute instead of qualified names can provide faster access. iconIndex The index number for the icon of the object in the Administration Tool. isDefaultReadable If set to true, indicates that this object is readable by default. isDefaultReadWriteable If set to true, indicates that this object is both readable and writable by default. isDefaultDeletable If set to true, indicates that this object is deletable by default. isDefaultGrantable If set to true, indicates that this object is grantable by default isDefaultAll If set to true, indicates that this object is readable, writable, deletable, and grantable by default. Table 12–2 Common XML Attributes in ref_t Attribute Name Description id The global unique identifier of the object, in the format type_ id :object_id. uid The internal identifier of the object. Referring to objects using this attribute instead of qualified names can provide faster access. qualifiedName The fully qualified name of the object. For example, the qualifiedName attribute for a logical column might appear as follows: qualifiedName=quot;Sample Salesquot;.quot;F3 Rolling Measuresquot;.quot;1-22L Revenue All Hist Sumquot; Table 12–1 Cont. Common XML Attributes in object_t Attribute Name Description About the Oracle BI Server XML API 12-15 The fully qualified name is the best identifier to use when searching an XML repository file to find a particular object, because the name of each object is visible in the Administration Tool. For example: qualifiedName=quot;Sample Salesquot;.quot;H0 Timequot;.quot;Monthquot; Note that qualified names for Presentation objects use .. between the subject area and the presentation table name. This syntax is used because there is no such thing as a presentation schema, which would normally go between a catalog and a table. For example: qualifiedName=quot;Sample Smallquot;..quot;Facts Revenuequot;.quot;Billed Qtyquot; A similar convention is used for Physical layer objects, when the database does not have a physical catalog or physical schema. ■ uid. This identifier, also called the UpgradeID, is a 32-bit number that is unique across the entire repository. The uid is created by the Oracle BI Server for the lifetime of the object. You can leave it blank when creating new objects in XML, because the server generates it automatically when it loads the RPD file. When you alter an object, make sure not to change the uid. The uid is used for compare and merge algorithms. It can also be useful for tracing relationships when analyzing or reverse-engineering XML metadata. For example: uid=73185 ■ id. This identifier, also called the VoidID, is created by the Oracle BI Server for the lifetime of the object. It is used in situations where the object type can be used to achieve better performance than the uid. Like the uid, you can leave the id blank when creating new objects in XML, because the server generates it automatically when it loads the RPD file. When you alter an object, make sure not to change the id. The id is a structure that contains two pieces of information: the type and a unique number within that type for example, 2000:123456. Each object type, such as a logical column, has a particular number associated with it for example, 2000. So, two objects of the same type both have the same number in the first part of the id. The unique number in the second part of the id is a randomly assigned number within that type. It must be unique within the type, but does not need to be unique across different object types. For example, a repository might have the valid ids 2000:123456 and 2001:123456. Although the id is typically created by the Oracle BI Server, you can create your own if needed, as long as you ensure that it is unique. For example: id=4010:1720

12.4.2 About Naming Requirements for Repository Objects

All repository object names must follow these requirements: ■ Names cannot be longer than 128 characters ■ Names cannot contain leading or trailing spaces ■ Names cannot contain single quotes, question marks, or asterisks Note that repository object names can include multibyte characters.