1

I had to work with a B2MML data scheme, which is essentially a special case of an xsd scheme designed for business needs. This scheme has a very branched structure of dependencies on other schemes (the connection is via include and import). The essence of the issue is that after expanding the standard with custom fields (added to the Extension.xsd standard) and trying to generate a class from the B2MML-V0600-ProductionSchedule.xsd scheme using the xsd.exe tool, an error fell into the console

Schema validation warning: Reference to undeclared model group 'http://www.mesa.org/xml/B2MML-V0600-AllExtensions:EquipmentAssetMapping'. Line 404, position 14.

Such messages in the console are of the order of> 50 for each connected group in B2MML-V0600-ProductionSchedule.xsd. Below this >50 rows I have got a error

Error: Error generating classes for schema '_\B2MML-V0600-ProductionSchedule'. - Group Location is missing.

One gets the feeling that the code section with the import did not work

<xsd:import     namespace="http://www.mesa.org/xml/B2MML-V0600-AllExtensions" 
        schemaLocation="B2MML-V0600-AllExtensions.xsd"/>

there is a similar question on the link Similar question

Who can advise and suggest how to fix the problem? Thanks in advance.

  • Does this answer your question? ["The element is missing.." trying to generate class with ](https://stackoverflow.com/questions/28903031/the-element-is-missing-trying-to-generate-class-with-element-ref) – tom redfern May 21 '20 at 17:40

1 Answers1

0

I have found question here Same quiestion

As a result: added to the line after the file name the main scheme from which the class was created, the name of the file whose import was registered in it. As I understand xsd application also works crookedly by importing other schemes (import instraction not unclude)

Community
  • 1
  • 1