1c data synchronization through the universal format products. Appearance and features of using universal data exchange

2018-11-15T19:32:35+00:00

Universal processing "Uploading and loading XML data" performs full or partial unloading of infobase data into a file in XML format. Subsequently, this file can be loaded into the infobase using the same processing. The upload file format differs from the file format created when uploading according to an exchange plan in the header part.

Processing can only be used in cases where the information base in which the data was uploaded and the one in which the data was loaded are homogeneous (the configurations are identical, the data may differ), or all the uploaded objects are almost completely identical in composition and types of details and table parts, properties of the “leading” metadata object, and so on.

The use of this processing is possible, for example, to create a full or partial backup copy of data, exchange data between infobases, and also as an auxiliary tool when restoring faulty infobases.

Processing supports data uploading with the ability to specify selection by period. Also implemented is checking objects for the presence of invalid characters when exchanged via XML.

Sincerely, (teacher and developer).

Send this article to my email

The main reasons for the need to implement exchange between 1C databases are the presence of branches and the separation of accounting types, because Often companies operate in several information databases. Setting up 1C 8.3 exchange allows you to eliminate double work - entering the same documents and directories in two programs, as well as quickly deliver the necessary system objects for various branches and departments.

In the case when it is necessary to exchange between branches, the RIB (Distributed Information Base) is used. This is an exchange mechanism between identical configurations. It represents a tree with the most important root node on top, below a pair of interconnected nodes. Changes can be made in any node of this system, and they will be transmitted to other connected nodes. It also distributes not only data, but also configuration changes from the root node to the slave nodes.

If it is necessary to separate types of accounting, for example, maintaining operational ones in the trading database, and regulated ones in the accounting database, universal exchange mechanisms with flexible data synchronization settings are available.

One of the latest 1C developments is the EnterpriseData data exchange format. It is easy to use and is intended for exchange within the company both between 1C databases and third-party programs.

The implementation of data exchange in an enterprise can be represented in the form of sequential procedures.

First of all, it is necessary to determine between which databases there should be an exchange; will it be a two-way or one-way exchange; if one-way, then which database will transmit information and which will only receive; if this is a complex branch network, then it is necessary to register a database construction scheme.

Then we select the appropriate format: RIB, universal format; exchange according to exchange rules; exchange without exchange rules.

The next step is to select a vehicle to carry out the exchange. A large selection of technologies is available, let’s highlight the main ones: directory (local or network), FTP resource, COM connections, web service, email.

The fourth step will be to identify the data: documents, reference books and, if necessary, detail them down to their individual details to be transferred.

And in conclusion, a schedule of exchange frequency is prescribed

Each option for setting up 1C 8.3 exchange requires careful preparation. Its implementation is beyond the capabilities of every user; it is necessary to take into account many nuances and understand the principles of the exchange. Particular attention will need to be paid to configuration if the databases: contain modifications or many additional ones. details, differ in platform versions or use outdated versions of configurations, the enterprise is large and uses an automated system consisting of a large number of databases. Errors are unacceptable here, because... may lead to irreparable consequences. Independent implementation of exchange in 1C is recommended only if you need to set up a simple transfer of information between standard configurations.

If you doubt your abilities, it is better not to save, but to contact a competent specialist who will help solve the complex problem of setting up 1C 8.3 exchanges.

If you still decide to configure 1C exchanges without involving experts, it is recommended to first test on copies of the databases, and before starting work in the working databases, upload the configurations to be able to return to the original state in case of errors.

Below we give a detailed example of setting up 1C 8.3 exchange unilaterally between standard configurations Trade Management 11 (UT) and Enterprise Accounting 3.0 (BP). The example is relevant for many companies engaged in wholesale and retail trade. In the UT, management accounting is maintained, in the BP - regulated, the exchange is necessary to facilitate the work of users.

This algorithm is also suitable for other standard configurations on the 1C 8.3 platform

First of all, we will carry out preparatory work for the information receiver, i.e. for BP. We launch the program in Enterprise mode. You need to set the Data synchronization constant (section Administration → Data synchronization).

Pay attention to the Prefix field; here you need to specify a value that will allow you to subsequently distinguish (by the value of the directory code or document number) in which program the objects were originally created. In our example, the usual abbreviation BP and UT is suitable, if the 1C 8.3 exchange setup is performed for a complex exchange between a large number of databases, as well as identical configurations, you will need to enter each database with its own clear designation.

Since the power supply unit is only a receiver of information, we proceed to setting up the UT.

Here, just like in the BP, you need to enable synchronization and specify a prefix. This information is available in the Master data and administration section → Data synchronization settings.

Select the setup method: Specify settings manually. Further.

Let's set up a direct connection option, when both programs are located on the same local network, specify the parameters for connecting to the information security directory on this network, and also fill in the user authentication information (in the BP database). Further.

The system will check the correctness of the specified data and, if the result is positive, will display the 1C 8.3 exchange settings window.

Click the Change data upload rules link to access settings for the exchange. We will clarify the master data - upload only those used in documents, select organizations and the option of working with contracts - without reference, separation of documents by warehouse. The exchange begins on March 1 of the current year.

We write down the introduced rules and close them.

Since the example is about one-way transmission of information, in the next settings window to receive data from another program, you should set the values ​​to Do not send. Record and close. Further.

Now you need to check the entered parameters and if they are correct, click Next, otherwise return to the previous step by clicking Back.

You will then be prompted to synchronize. Click Finish.

If it is necessary to correlate identical objects of two configurations, a window for comparing data will open. We perform the comparison and click Next.

When transferring objects, problematic situations may arise; you can view the results by clicking the Warnings during data synchronization link.

After synchronization is completed, a window will be displayed confirming the successful completion of this process.

Here, using the Configure command or later, in the synchronization script, you can configure a schedule for automatically performing the exchange.

What is needed for automatic data exchange, without making configuration changes:
1) Processing "Universal Data Interchange in XML Format", which is included in most standard configurations. If it is not there, then it is easy to find it on the ITS disk or on the Internet. In the configuration it is called "Universal XML Data Exchange"
2) Data exchange rules. Created using "Data Conversion". A job that you will have to master. There are also video courses and tutorials. For example: http://programmist1s.ru/wp-content/uploads/2013/06/Konvertatsiya_dannyih._Metodika_rabotyi_i_primeryi.pdf
3) External processing, containing loading/unloading procedures. Let's start creating it:
An external processing is created in the object module which will contain the text below (substitute your data for databases and users). It is advisable to create a separate user with full rights to exchange data. Let's call the processing, for example, "Data Exchange.epf".

If LaunchParameter = "Upload" Then Processing=Processing.UniversalXMLDataExchange.Create(); FindByCode("BP20");

4) Bat file upload, which will launch 1C and external processing with the launch parameter under the user, which is intended for data exchange. The file must be created, for example, in notepad++ with OEM (MS-Dos) encoding, otherwise it will not work. Let's name the file, for example, "BatVygruz.bat". The text will be as follows:

If the database is file:
"C:\Program Files (x86)\1cv82\common\1cestart.exe" ENTERPRISE /F"C:\Inbox\KBF\1Cv8_Base_8.1\Zeus 83 BP3\Zeus 83 BP3" /N"Data Exchange Robot" /P"pass " /DisableStartupMessages /RunModeManagedApplication /Execute"C:\Inbox\OlegA\DataExchange.epf" /C"Upload"
Explanations:

b) C:\Inbox\KBF\1Cv8_Base_8.1\Zeus 83 BP3\Zeus 83 BP3 - your path to the file database from which we will upload data
c) Data Exchange Robot - User name under which 1C runs for data exchange
d) pass - user password
e) /DisableStartupMessages - close pop-up windows when starting 1C
e) /RunModeOrdinaryApplication - run the thick client in normal mode
g) C:\Inbox\OlegA\Data Exchange.epf - the path to our processing, which will start at startup
h) Upload - we pass the 1C launch parameter, it tells us that we need to upload data

If the database is server-based:
"C:\Program Files (x86)\1cv82\common\1cestart.exe" ENTERPRISE /S"Server1C/DataBase" /N"Data Exchange Robot" /P"pass" /DisableStartupMessages /RunModeManagedApplication /Execute"C:\Inbox\Oleg\ Data Exchange.epf" /C"Upload"
Explanations:
a) C:\Program Files (x86)\1cv82\common\1cestart.exe - your path to the 1C starter
b) Server1C/DataBase - your server on which the database is located and the name of the database itself from which we upload data.
The remaining parameters are similar to the file version of the bat file

5) Bat file download (if necessary). If you decide to upload data to a file and not directly to the database. Then we will also need this item (usually necessary).
Creating a Bat download file is similar to the upload file, but only the launch parameter is different, instead of “Upload”, we put “Download”

6) Set a launch schedule our Bat files loading/uploading on the server. To do this, you need to go to the administration of the control panel on the server and in the task scheduler create a new task to run the download file at 23 o'clock every day and a download task specifying the Bat download file (if necessary) at 04 o'clock for example.

mob_info