12345678910111213141516171819202122232425262728293031323334 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed Materials - Property of IBM
- IBM Cognos Products: ps
- (C) Copyright IBM Corp. 2005, 2011
- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- -->
- <!--
- Copyright (C) 2009 Cognos ULC, an IBM Company. All rights reserved.
- Cognos (R) is a trademark of Cognos ULC, (formerly Cognos Incorporated).
- -->
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:xts="http://developer.cognos.com/schemas/xts/"
- exclude-result-prefixes="xsl xts">
- <xsl:output method="xml" version="1.0" encoding="UTF-8"/>
- <xsl:key name="env-param" match="/root/env/param" use="@name"/>
- <xsl:variable name="queryServiceEquivalent" select="/root/datasources/datasource[value=key('env-param', 'm_connection_type')]/queryServiceEquivalent"></xsl:variable>
- <xsl:template match="/root">
- <datasources>
- <xsl:copy-of select="/root/datasources/datasource[value=key('env-param', 'm_connection_type')]"/>
- </datasources>
- <xsl:if test="/root/getJDBCDatasource='true' and $queryServiceEquivalent!=''">
- <jdbcdatasources>
- <xsl:copy-of select="/root/datasources/datasource[value=$queryServiceEquivalent]"/>
- </jdbcdatasources>
- </xsl:if>
- </xsl:template>
- </xsl:stylesheet>
|