Импорт 1ДФ в Медок из 1С

Проблеми зв'язані з експортом\імпортом звітів, довідників.
Відповісти
VladM
Повідомлень: 21
З нами з: 06 вересня 2017, 10:59

Импорт 1ДФ в Медок из 1С

Повідомлення VladM » 10 жовтня 2017, 13:53

Добрый день. Ситуация такая, пытаются импортировать 1ДФ из 1С в форматах XML и DBF выбиваются вот такие ошибки (...). 3 раза его пересоздавали в 1С. Сейчас версия 198, но проблема уже 2 недели, т.е. 196, 197, 198 версия. Медок локальный 196-198, Win 7.
Вкладення
DBF.JPG
DBF.JPG (49.3 Кіб) Переглянуто 1329 разів
XML.JPG
XML.JPG (58.28 Кіб) Переглянуто 1329 разів

Белокопытов Геннадий
Универсал (склонность - системные вопросы)
Повідомлень: 10116
З нами з: 13 січня 2012, 11:21

Re: Импорт 1ДФ в Медок из 1С

Повідомлення Белокопытов Геннадий » 10 жовтня 2017, 14:22

VladM
Ошибка может быть в структуре самого файла.
Просьба прикрепить пример такого файла XML и DBF для проверки.

Inkognito
Повідомлень: 1067
З нами з: 14 січня 2012, 14:26

Re: Импорт 1ДФ в Медок из 1С

Повідомлення Inkognito » 10 жовтня 2017, 14:25

HTINSTI відсутній в схемі XSD. Видно, Ви його неправильно назвали.
J0500105.xsd | Показать
<?xml version="1.0" encoding="windows-1251"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:annotation>
<xs:documentation>
Податковий розрахунок сум доходу, нарахованого (сплаченого) на користь фізичних осіб, і сум утриманого з них податку [Форма № 1 ДФ] (Затверджено наказом Міністерства фінансів України від13.01.2015 року № 4)
</xs:documentation>
</xs:annotation>
<xs:include schemaLocation="common_types.xsd"/>
<xs:element name="DECLAR" type="DeclarContent"/>
<xs:complexType name="DeclarContent">
<xs:sequence>
<xs:element name="DECLARHEAD" type="DHead" minOccurs="1" maxOccurs="1"/>
<xs:element name="DECLARBODY" type="DBody" minOccurs="1" maxOccurs="1">
<xs:unique name="UT1RXXXXG02">
<xs:selector xpath="T1RXXXXG02"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG03A">
<xs:selector xpath="T1RXXXXG03A"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG03">
<xs:selector xpath="T1RXXXXG03"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG04A">
<xs:selector xpath="T1RXXXXG04A"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG04">
<xs:selector xpath="T1RXXXXG04"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG05">
<xs:selector xpath="T1RXXXXG05"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG06D">
<xs:selector xpath="T1RXXXXG06D"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG07D">
<xs:selector xpath="T1RXXXXG07D"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG08">
<xs:selector xpath="T1RXXXXG08"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
<xs:unique name="UT1RXXXXG09">
<xs:selector xpath="T1RXXXXG09"/>
<xs:field xpath="@ROWNUM"/>
</xs:unique>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="DHead">
<xs:sequence>
<xs:element name="TIN" type="DGLong" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC" type="xs:string" fixed="J05" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_SUB" type="xs:string" fixed="001" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_VER" type="xs:string" fixed="5" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_TYPE" type="xs:nonNegativeInteger" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_CNT" type="xs:nonNegativeInteger" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_REG" type="DGsti" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_RAJ" type="DGsti" minOccurs="1" maxOccurs="1"/>
<xs:element name="PERIOD_MONTH" type="DGMonth" minOccurs="1" maxOccurs="1"/>
<xs:element name="PERIOD_TYPE" type="DGPType" minOccurs="1" maxOccurs="1"/>
<xs:element name="PERIOD_YEAR" type="DGYear" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_STI_ORIG" type="DGc_dpi" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_STAN" type="DGSTAN" minOccurs="1" maxOccurs="1"/>
<xs:element name="LINKED_DOCS" nillable="true" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="DOC" minOccurs="1" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="C_DOC" type="DGC_DOC" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_SUB" type="DGC_DOC_SUB" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_VER" type="DGC_DOC_VER" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_TYPE" type="xs:nonNegativeInteger" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_CNT" type="xs:nonNegativeInteger" minOccurs="1" maxOccurs="1"/>
<xs:element name="C_DOC_STAN" type="DGSTAN" minOccurs="1" maxOccurs="1"/>
<xs:element name="FILENAME" type="DGFilename" minOccurs="1" maxOccurs="1"/>
</xs:sequence>
<xs:attribute name="NUM" type="xs:nonNegativeInteger"/>
<xs:attribute name="TYPE" type="DGTypeLinkDoc"/>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:unique name="UH_DOC_NUM">
<xs:selector xpath="DOC"/>
<xs:field xpath="@NUM"/>
</xs:unique>
</xs:element>
<xs:element name="D_FILL" type="DGDate" minOccurs="1" maxOccurs="1"/>
<xs:element name="SOFTWARE" type="xs:string" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="DBody">
<xs:sequence>
<!--HEAD-->
<xs:element name="HTIN" type="DGHTINJ" minOccurs="1" maxOccurs="1"/>
<xs:element name="HPAGES" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<xs:choice minOccurs="1" maxOccurs="1">
<xs:element name="HZ" type="DGchk"/>
<xs:element name="HZN" type="DGchk"/>
<xs:element name="HZU" type="DGchk"/>
</xs:choice>
<xs:element name="HNAME" type="DGHNAME" minOccurs="1" maxOccurs="1"/>
<xs:element name="HLOC" type="DGHLOC" minOccurs="1" maxOccurs="1"/>
<xs:element name="HSTI" type="DGHSTI" minOccurs="1" maxOccurs="1"/>
<xs:element name="HZKV" type="DGKv" minOccurs="1" maxOccurs="1"/>
<xs:element name="HZY" type="DGYear" minOccurs="1" maxOccurs="1"/>
<!--BODY-->
<xs:element name="R00G01I" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<xs:element name="R00G02I" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<xs:element name="R00G03I" type="DGI4nom" minOccurs="1" maxOccurs="1"/>
<!--TABLE №1-->
<xs:element name="T1RXXXXG02" type="TinColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG03A" type="Decimal2Column" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG03" type="Decimal2Column" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG04A" type="Decimal2Column" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG04" type="Decimal2Column" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG05" type="Odoh1DFColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG06D" type="DateColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG07D" type="DateColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG08" type="Oplg1DFColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<xs:element name="T1RXXXXG09" type="OznColumn" nillable="true" minOccurs="0" maxOccurs="99999"/>
<!--/TABLE №1-->
<xs:element name="R01G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R01G03" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R01G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R01G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0201G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0201G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0201G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0202G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0202G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0202G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0203G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0203G03" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0203G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0203G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0204G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0204G03" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0204G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0204G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0205G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0205G03" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0205G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0205G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0206G03A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0206G03" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0206G04A" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R0206G04" type="DGdecimal2" nillable="true" minOccurs="0"/>
<xs:element name="R02G01I" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<xs:element name="R02G02I" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<xs:element name="R02G03I" type="xs:nonNegativeInteger" nillable="true" minOccurs="0"/>
<!--FOOTER-->
<xs:element name="HFILL" type="DGDate" minOccurs="1" maxOccurs="1"/>
<xs:element name="HKBOS" type="DGLong" minOccurs="1" maxOccurs="1"/>
<xs:element name="HBOS" type="DGHBOS" minOccurs="1" maxOccurs="1"/>
<xs:element name="HTELBOS" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="HKBUH" type="DGLong" nillable="true" minOccurs="0"/>
<xs:element name="HBUH" type="DGHBUH" nillable="true" minOccurs="0"/>
<xs:element name="HTELBUH" type="xs:string" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
П.С. в описі помилки англійською мовою написано "Елемент HTINSTI не задано в схемі XSD, очікується елемент HSTI".
Спробуйте перейменувати елемент при вивантаженні з HTINSTI на HSTI

Відповісти

Повернутись до “Експорт\імпорт”