Book a Demo

Author Topic: Importing and exporting schemas and namespace issues  (Read 3318 times)

Victoria N

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Importing and exporting schemas and namespace issues
« on: April 22, 2008, 08:21:06 pm »
I am currently investigating tools to use for generating metadata profiles in in xsd format. A schema has beed put together using XML spy and loaded into EA. It was then exported out of EA back into an xml schema using the following technique.

Import
Project - Import XML Schema - Navigated to schema location and selected Import.
Export
Project - Generate Schema - Entered a name for it and selected  generate including UTF-8 in the encoding section.

The file header that was imported was as follows

<xsd:schema xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.loc.gov/mods/v3" targetNamespace="http://www.loc.gov/mods/v3" elementFormDefault="qualified" attributeFormDefault="unqualified">
      <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
      <xsd:import namespace="http://www.w3.org/1999/xlink" schemaLocation="http://www.loc.gov/standards/xlink.xsd"/>
      <!--
But the import lost the references to the import namespaces.
These were subsequently added in via XSD Schema properties

but still did not export into the header.

Then packages were added to represent the schema links with external refences included. However there was no positive effect. The code that IS generated in the header is as follows.

<xsd:schema targetNamespace="http://www.loc.gov/mods/v3" xmlns:xsd="http://www.w3.org/1999/xlink" elementFormDefault="qualified">

Any hints as to were to go. I have also played around with setting the import namespaces as root namespaces with no joy.

Martin Terreni

  • EA User
  • **
  • Posts: 672
  • Karma: +0/-0
  • Sorry, I can't write
    • View Profile
Re: Importing and exporting schemas and namespace issues
« Reply #1 on: April 23, 2008, 03:49:28 pm »
I think you better report a bug. I had been having trouble also working with XMLspy.
Recursion definition:
If you don’t understand the definition read "Recursion definition".