Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 361634 - Namespace issue with XML Schemas in the New Data Set wizard
Summary: Namespace issue with XML Schemas in the New Data Set wizard
Status: NEW
Alias: None
Product: Data Tools
Classification: Tools
Component: Connectivity (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: dtp.connectivity-inbox CLA
QA Contact: weiming tang CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-21 07:06 EDT by James Pasley CLA
Modified: 2014-09-03 14:31 EDT (History)
3 users (show)

See Also:


Attachments
XML Schema that can be used to reproduce the problem (807 bytes, application/octet-stream)
2011-10-21 07:07 EDT, James Pasley CLA
no flags Details
Example of a report containing the incorrect XPath expressions (11.10 KB, text/plain)
2011-10-21 07:07 EDT, James Pasley CLA
no flags Details
Example of a report where the XPath expressions have been fixed by hand (11.40 KB, text/plain)
2011-10-21 07:08 EDT, James Pasley CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description James Pasley CLA 2011-10-21 07:06:04 EDT
Build Identifier: v20110913-1734

When creating a new data set using the New Data Set wizard for an XML Data Source defined using an XML Schema, the XPath expressions are incorrect.

Attached is a simple XML Schema (ReportInput.xsd) created using the XML Schema editor in eclipse. I created a report (ReportFromXML.rptdesign) containing an XML data source based on this XML Schema. I then created a data set using the New Data Set wizard. The XPath expressions it generated don’t include a namespace prefix. For example, this was generated as the row mapping XPath expression: /Report_Data/Report_Entry

The XML Schema defines a targetNamespace, so the expression should be /tns:Report_Data/tns:Report_Entry.
	
Once the XPath expressions are fixed by hand as shown in FixedReportFromXML.repdesign, the report works correctly.

Reproducible: Always

Steps to Reproduce:
1. Create a new blank report
2. Create a new XML Data Source. Select the XML Schema attached to this bug report as the XML Schema on the Define XML Data Source step of the New XML Data Source wizard and click Finish.
3.Create a new Data Set, on the Row Mapping step of the wizard, select the Report_Data/Report_Entry node in the tree and click on the “>” button. Click OK on the dialog that appears.

Note that the Xpath expression displayed on the wizard is /Report_Data/Report_Entry. It should be /tns:Report_Data/tns:Report_Entry.
Comment 1 James Pasley CLA 2011-10-21 07:07:20 EDT
Created attachment 205709 [details]
XML Schema that can be used to reproduce the problem
Comment 2 James Pasley CLA 2011-10-21 07:07:51 EDT
Created attachment 205710 [details]
Example of a report containing the incorrect XPath expressions
Comment 3 James Pasley CLA 2011-10-21 07:08:19 EDT
Created attachment 205711 [details]
Example of a report where the XPath expressions have been fixed by hand