Меню

Cvc elt 1 a cannot find the declaration of element эдпфр код ошибки

I have to handwriting an sample xml for my xsd, but I always get invalid message: cvc-elt.1.a: Cannot find the declaration of element ‘RS_WMS_GET_PO_DATA_v2.0’.

My XSD:

<?xml version="1.0" encoding="utf-16"?>
<schema xmlns:ns0="http://www.rossinc.com/" xmlns:msbtsdml="http://schemas.rossinc.com/BizTalk" xmlns:b="http://schemas.microsoft.com/BizTalk/2003" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://www.rossinc.com/" xmlns="http://www.w3.org/2001/XMLSchema">
  <annotation>
    <appinfo>
      <msbtsdml:StoredProcedureName xmlns:msbtsdml="http://schemas.rossinc.com/BizTalk/DMLAdapter">RS_WMS_GET_PO_DATA</msbtsdml:StoredProcedureName>
      <msbtsdml:ResponseRootName xmlns:msbtsdml="http://schemas.rossinc.com/BizTalk/DMLAdapter">poData</msbtsdml:ResponseRootName>
    </appinfo>
  </annotation>
  <element name="RS_WMS_GET_PO_DATA_v2.0">
    <complexType>
      <sequence>
        <element minOccurs="1" maxOccurs="1" name="Parameters">
          <complexType>
            <sequence>
              <element default="0" name="ERROR_OCCURRED" type="string">
                <annotation>
                  <appinfo>
                    <msbtsdml:ParamDir xmlns:msbtsdml="http://schemas.microsoft.com/BizTalk/2003">In</msbtsdml:ParamDir>
                  </appinfo>
                </annotation>
              </element>
              <element default="1" name="XML_TAGS" type="int">
                <annotation>
                  <appinfo>
                    <msbtsdml:ParamDir xmlns:msbtsdml="http://schemas.microsoft.com/BizTalk/2003">In</msbtsdml:ParamDir>
                  </appinfo>
                </annotation>
              </element>
              <element default="0" name="NUM_ROWS" type="int">
                <annotation>
                  <appinfo>
                    <msbtsdml:ParamDir xmlns:msbtsdml="http://schemas.microsoft.com/BizTalk/2003">In</msbtsdml:ParamDir>
                  </appinfo>
                </annotation>
              </element>
            </sequence>
          </complexType>
        </element>
        <element name="RS_WMS_GET_PO_DATA">
          <complexType>
            <all minOccurs="1" maxOccurs="1">
              <element name="COMPANY_CODE" type="string" />
              <element name="DIVISION" type="string" />
              <element name="PO_NUMBER" type="string" />
              <element name="PO_WH_SEQUENCE" type="string" />
              <element name="ERP_ACTION_CODE" type="string" />
            </all>
          </complexType>
        </element>
        <element name="DMLAdapterConfig">
          <complexType>
            <sequence>
              <element name="EnvironmentId" type="string" />
            </sequence>
          </complexType>
        </element>
      </sequence>
    </complexType>
  </element>
</schema>

My XML:

<?xml version="1.0" encoding="UTF-8"?>
<RS_WMS_GET_PO_DATA_v2.0>
    <Parameters>
        <ERROR_OCCURRED>0</ERROR_OCCURRED>
        <XML_TAGS>1</XML_TAGS>
        <NUM_ROWS>0</NUM_ROWS>
    </Parameters>
    <RS_WMS_GET_PO_DATA>
        <COMPANY_CODE></COMPANY_CODE>
        <DIVISION></DIVISION>
        <PO_NUMBER></PO_NUMBER>
        <PO_WH_SEQUENCE></PO_WH_SEQUENCE>
        <ERP_ACTION_CODE></ERP_ACTION_CODE>
    </RS_WMS_GET_PO_DATA>
    <DMLAdapterConfig>
        <EnvironmentId></EnvironmentId>
    </DMLAdapterConfig>
</RS_WMS_GET_PO_DATA_v2.0>

Any ideas?

Here’s the website I’m using:
http://www.corefiling.com/opensource/schemaValidate.html

asked May 8, 2013 at 9:03

vash_ace's user avatar

1

<?xml version="1.0" encoding="UTF-8"?>
<ns0:RS_WMS_GET_PO_DATA_v2.0 xmlns:ns0="http://www.rossinc.com/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.rossinc.com/ One.xsd ">
<ns0:Parameters>
<ns0:ERROR_OCCURRED>0</ns0:ERROR_OCCURRED>
<ns0:XML_TAGS>1</ns0:XML_TAGS>
<ns0:NUM_ROWS>0</ns0:NUM_ROWS>
</ns0:Parameters>
<ns0:RS_WMS_GET_PO_DATA>
<ns0:COMPANY_CODE>ns0:COMPANY_CODE</ns0:COMPANY_CODE>
<ns0:DIVISION>ns0:DIVISION</ns0:DIVISION>
<ns0:PO_NUMBER>ns0:PO_NUMBER</ns0:PO_NUMBER>
<ns0:PO_WH_SEQUENCE>ns0:PO_WH_SEQUENCE</ns0:PO_WH_SEQUENCE>
<ns0:ERP_ACTION_CODE>ns0:ERP_ACTION_CODE</ns0:ERP_ACTION_CODE>
</ns0:RS_WMS_GET_PO_DATA>
<ns0:DMLAdapterConfig>
<ns0:EnvironmentId>ns0:EnvironmentId</ns0:EnvironmentId>
</ns0:DMLAdapterConfig>
</ns0:RS_WMS_GET_PO_DATA_v2.0>

As because you did not mentioned which schema file to use for this XML file. I think tis will solve your problem.

answered May 8, 2013 at 10:53

Madhusudan Joshi's user avatar

Madhusudan JoshiMadhusudan Joshi

4,3983 gold badges24 silver badges41 bronze badges

4

I had an error

cvc-elt.1.a: Cannot find the declaration of element problem!

I solved it this way:

  1. Look for your XSD file, if it has a xmlns attribute, for instance:

    xmlns="http://yourcompany/blablabla/rootElementName"
    
  2. Look into your XML file, it must have an xmlns attribute if the XSD has defined one.

    <rootElement xmlns="http://company/xxxxxx/rootElementName">
    
  3. XML is case sensitive. Review your XML tags and compare them with the XSD tags.

Regards!

zx485's user avatar

zx485

27.8k28 gold badges54 silver badges59 bronze badges

answered Dec 11, 2013 at 11:58

antmarmo's user avatar

0

  1. Главная
  2. Форум
  3. Учет, налогообложение, автоматизация
  4. СЗВ-ТД ошибка cvc-elt.1.a: Cannot find the declaration of element ‘ЭДПФР

Показывать по
10
20
40
сообщений

Новая тема

Ответить

Письмо в техподдержку 1С

отправить копию письма на мой адрес

отправить копию письма на адрес:

[Прочее]

Наталья Ейриш

Дата регистрации: 11.11.2015
Сообщений: 6

Добрый вечер! Отправили СЗВ-ТД по новой форме, ЗУП 3.1.14.587, патчи установлены. От ПФР приходит в ответ ошибка cvc-elt.1.a: Cannot find the declaration of element ‘ЭДПФР’. В файле выгрузки ЭДПФР присутствует. С чем может быть связана данная ошибка?

Показывать по
10
20
40
сообщений

Notice! This page describes the nature of the error using a hypothetical example and not the erroneous data of the input test file. You should however be able to apply this information to your error case.

General description of the error:

The format of the error message: cvc-elt.1: Cannot find the declaration of element »{0}».

Error description in schema standard: http://www.w3.org/TR/2007/WD-xmlsche…#cvc-attribute

Possible causes for this error:

  • The validated file has a namespace which doesn’t match the target namespace («targetNamespace») defined in the schema.
  • Validated file does not have namespace («xmlns») defined even though schema has «targetNamespace».
    • If schema has «targetNamespacesomeNamespace«» then the validated file must match this with «xmlnssomeNamespace«».
  • There might be extra spaces or minor typing mistakes in the xmlns=»» attribute also.
  • Inserted XML does not match the schema used in the pipe

An example

Error messageError cvc-elt.1: Cannot find the declaration of element ‘Document’.

How to fix: The element Document is not in the same namespace which is defined as a target namespace in the schema — i.e. the value given in default namespace attribute (xmlns) is incorrect. You have to check the schema to see what is the targetNamespace defined in there.

The schema definition could be e.g. following:

<xs:schema ... targetNamespace="urn:iso:std:iso:20022:tech:xsd:pain.001.001.03" ... >

Valid document tag could then look like this:

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and
privacy statement. We’ll occasionally send you account related emails.

Already on GitHub?
Sign in
to your account


Closed

az-oolloow opened this issue

Sep 22, 2021

· 4 comments

Comments

@az-oolloow

Summary

Short summary of what is going on or to provide context.

Steps To Reproduce:

  1. Retrieve a source file using Org browser
  2. Open -meta.xml

Expected result

No XML validation errors and/or XML validates successfully

Actual result

Error cvc-elt.1.a: Cannot find the declaration of element will be shown at the root element

Additional information

Salesforce Extension Version in VS Code: v52.13.0

SFDX CLI Version: sfdx-cli/7.116.2 darwin-x64 node-v14.17.5

OS and version: macOS Big Sur 11.6

@randi274

@az-oolloow is this happening every time you view a meta.xml file?

@az-oolloow

@randi274 I looked into this further.

Apparently only some files produce it. For example, LightningComponentBundle root tag in meta file is fine, but e.g. Layout, CustomApplication, CustomObject are not fine.

@randi274

Thanks for the further information @az-oolloow! I tried to reproduce it by retrieving a CustomObject, but I’m not seeing the issue. Are you able to make changes and deploy to the org?

@no-response

This issue has been automatically closed because there has been no response to our request for more information from the original author. Currently, there is not enough information provided for us to take action. Please reply and reopen this issue if you need additional assistance.

0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии

А вот еще интересные материалы:

  • Яшка сломя голову остановился исправьте ошибки
  • Ясность цели позволяет целеустремленно добиваться намеченного исправьте ошибки
  • Ясность цели позволяет целеустремленно добиваться намеченного где ошибка
  • Custom error code ошибка
  • Curtis sepex traction controller 1243 4220 ошибки