Primeur Online Docs
Data Shaper
Data Shaper
  • 🚀GETTING STARTED
    • What is Primeur Data Shaper
      • What is the Data Shaper Designer
      • What is the Data Shaper Server
      • What is the Data Shaper Cluster
    • How does the Data Shaper Designer work
      • Designer Views and Graphs
      • Data Shaper Graphs
      • Designer Projects and Sandboxes
      • Data Shaper Designer Reference
    • How do the Data Shaper Server and Cluster work
      • Data Shaper Server and Cluster
      • Data Shaper Server Reference
    • VFS Graph Components
      • DataOneFileDescriptor (DOFD) metadata
      • Passing parameters from Data One Contract to Data Shaper graph
      • Inheriting Data One context attributes in Data Shaper graph
  • DATA SHAPER DESIGNER
    • Configuration
      • Runtime configuration
        • Logging
        • Master Password
        • User Classpath
      • Data Shaper Server Integration
      • Execution monitoring
      • Java configuration
      • Engine configuration
      • Refresh Operation
    • Designer User Interface
      • Graph Editor with Palette of Components
      • Project Explorer Pane
      • Outline Pane
      • Tabs Pane
      • Execution Tab
      • Keyboard Shortcuts
    • Projects
      • Creating Data Shaper projects
      • Converting Data Shaper projects
      • Structure of Data Shaper projects
      • Versioning of server project content
      • Working with Data Shaper Server Projects
      • Project configuration
    • Graphs
      • Creating an empty graph
      • Creating a simple graph
        • Placing Components
        • Placing Components from Palette
        • Connecting Components with Edges
    • Execution
      • Successful Graph Execution
      • Run configuration
      • Connecting to a running job
      • Graph states
    • Common dialogs
      • URL file dialog
      • Edit Value dialog
      • Open Type dialog
    • Import
      • Import Data Shaper projects
      • Import from Data Shaper server sandbox
      • Import graphs
      • Import metadata
    • Export
      • Export graphs to HTML
      • Export to Data Shaper Server sandbox
      • Export image
      • Export Project as Library
    • Graph tracking
      • Changing record count font size
    • Search functionality
    • Working with Data Shaper server
      • Data Shaper server project basic principles
      • Connecting via HTTP
      • Connecting via HTTPS
      • Connecting via Proxy Server
    • Graph components
      • Adding components
      • Finding components
      • Edit component dialog box
      • Enable/disable component
      • Passing data through disabled component
      • Common properties of components
      • Specific attribute types
      • Metadata templates
    • Edges
      • Connecting Components with Edges
      • Types of Edges
      • Assigning Metadata to Edges
      • Colors of Edges
      • Debugging Edges
      • Edge Memory Allocation
    • Metadata
      • Records and Fields
        • Record Types
        • Data Types in Metadata
        • Data Formats
        • Locale and Locale Sensitivity
        • Time Zone
        • Autofilling Functions
      • Metadata Types
        • Internal Metadata
        • External (Shared) Metadata
        • SQL Query Metadata
        • Reading Metadata from Special Sources
      • Auto-propagated Metadata
        • Sources of Auto-Propagated Metadata
        • Explicitly Propagated Metadata
        • Priorities of Metadata
        • Propagation of SQL Query Metadata
      • Creating Metadata
        • Extracting Metadata from a Flat File
        • Extracting Metadata from an XLS(X) File
        • Extracting Metadata from a Database
        • Extracting Metadata from a DBase File
        • Extracting Metadata from Salesforce
        • SQL Query Metadata
        • User Defined Metadata
      • Merging Existing Metadata
      • Creating Database Table from Metadata and Database Connection
      • Metadata Editor
        • Opening Metadata Editor
        • Basics of Metadata Editor
        • Record Pane
        • Field Name vs. Label vs. Description
        • Details Pane
      • Changing and Defining Delimiters
      • Editing Metadata in the Source Code
      • Multi-value Fields
        • Lists and Maps Support in Components
        • Joining on multivalue fields (Comparison Rules)
    • Connections
      • Database Connections
        • Internal Database Connections
        • External (Shared) Database Connections
        • Database Connections Properties
        • Encryption of Access Password
        • Browsing Database and Extracting Metadata from Database Tables
        • Windows Authentication on Microsoft SQL Server
        • Snowflake Connection
        • Hive Connection
        • Troubleshooting
      • JMS Connections
      • QuickBase Connections
      • Hadoop Connections
      • Kafka Connections
      • OAuth2 Connections
      • MongoDB Connections
      • Salesforce Connections
    • Lookup Tables
      • Lookup Tables in Cluster Environment
      • Internal Lookup Tables
      • External (Shared) Lookup Tables
      • Types of Lookup Tables
    • Sequences
      • Persistent Sequences
      • Non Persistent Sequences
      • Internal Sequences
      • External (Shared) Sequences
      • Editing a Sequence
      • Sequences in Cluster Environment
    • Parameters
      • Internal Parameters
      • External (Shared) Parameters
      • Secure Graph Parameters
      • Graph Parameter Editor
      • Secure Graph Parameters
      • Parameters with CTL2 Expressions (Dynamic Parameters)
      • Environment Variables
      • Canonicalizing File Paths
      • Using Parameters
    • Internal/External Graph Elements
    • Dictionary
      • Creating a Dictionary
      • Using a Dictionary in Graphs
    • Execution Properties
    • Notes in Graphs
      • Placing Notes into Graph
      • Resizing Notes
      • Editing Notes
      • Formatted Text
      • Links from Notes
      • Folding Notes
      • Notes Properties
    • Transformations
      • Defining Transformations
      • Transform Editor
      • Common Java Interfaces
    • Data Partitioning (Parallel Running)
    • Data Partitioning in Cluster
      • High Availability
      • Scalability
      • Graph Allocation Examples
      • Example of Distributed Execution
      • Remote Edges
    • Readers
      • Common Properties of Readers
      • ComplexDataReader
      • DatabaseReader
      • DataGenerator
      • DataOneVFSReader
      • EDIFACTReader
      • FlatFileReader
      • JSONExtract
      • JSONReader
      • LDAPReader
      • MultiLevelReader
      • SpreadsheetDataReader
      • UniversalDataReader
      • X12Reader
      • XMLExtract
      • XMLReader
      • XMLXPathReader
    • Writers
      • Common Properties of Writers
      • DatabaseWriter
      • DataOneVFSWriter
      • EDIFACTWriter
      • FlatFileWriter
      • JSONWriter
      • LDAPWriter
      • SpreadsheetDataWriter
      • HIDDEN StructuredDataWriter
      • HIDDEN TableauWriter
      • Trash
      • UniversalDataWriter
      • X12Writer
      • XMLWriter
    • Transformers
      • Common Properties of Transformers
      • Aggregate
      • Concatenate
      • DataIntersection
      • DataSampler
      • Dedup
      • Denormalizer
      • ExtSort
      • FastSort
      • Filter
      • Map
      • Merge
      • MetaPivot
      • Normalizer
      • Partition
      • Pivot
      • Rollup
      • SimpleCopy
      • SimpleGather
      • SortWithinGroups
      • XSLTransformer
    • Joiners
      • Common Properties of Joiners
      • Combine
      • CrossJoin
      • DBJoin
      • ExtHashJoin
      • ExtMergeJoin
      • LookupJoin
      • RelationalJoin
    • Others
      • Common Properties of Others
      • CheckForeignKey
      • DBExecute
      • HTTPConnector
      • LookupTableReaderWriter
      • WebServiceClient
    • CTL2 - Data Shaper Transformation Language
    • Language Reference
      • Program Structure
      • Comments
      • Import
      • Data Types in CTL2
      • Literals
      • Variables
      • Dictionary in CTL2
      • Operators
      • Simple Statement and Block of Statements
      • Control Statements
      • Error Handling
      • Functions
      • Conditional Fail Expression
      • Accessing Data Records and Fields
      • Mapping
      • Parameters
      • Regular Expressions
    • CTL Debugging
      • Debug Perspective
      • Importing and Exporting Breakpoints
      • Inspecting Variables and Expressions
      • Examples
    • Functions Reference
      • Conversion Functions
      • Date Functions
      • Mathematical Functions
      • String Functions
      • Mapping Functions
      • Container Functions
      • Record Functions (Dynamic Field Access)
      • Miscellaneous Functions
      • Lookup Table Functions
      • Sequence Functions
      • Data Service HTTP Library Functions
      • Custom CTL Functions
      • CTL2 Appendix - List of National-specific Characters
      • HIDDEN Subgraph Functions
    • Tutorial
      • Creating a Transformation Graph
      • Filtering the records
      • Sorting the Records
      • Processing Speed-up with Parallelization
      • Debugging the Java Transformation
  • DATA SHAPER SERVER
    • Introduction
    • Administration
      • Monitoring
    • Using Graphs
      • Job Queue
      • Execution History
      • Job Inspector
    • Cluster
      • Sandboxes in Cluster
      • Troubleshooting
  • Install Data Shaper
    • Install Data Shaper
      • Introduction to Data Shaper installation process
      • Planning Data Shaper installation
      • Data Shaper System Requirements
      • Data Shaper Domain Master Configuration reference
      • Performing Data Shaper initial installation and master configuration
        • Creating database objects for PostgreSQL
        • Creating database objects for Oracle
        • Executing Data Shaper installer
        • Configuring additional firewall rules for Data Shaper
Powered by GitBook
On this page
  • Short Description
  • Ports
  • Metadata
  • EDIFACTWriter Attributes
  • Details
  • Autofilled segments
  • Examples
  • See also
  1. DATA SHAPER DESIGNER
  2. Writers

EDIFACTWriter

PreviousDataOneVFSWriterNextFlatFileWriter

Short Description

EDIFACTWriter writes data in the EDIFACT format. All EDIFACT versions from D.93A to D.21A are supported.

EDIFACTWriter is currently only available in certain plans. To find out more about licensing requirements, please contact .

COMPONENT
DATA OUTPUT
INPUT PORTS
OUTPUT PORTS
TRANSFORMATION
TRANSF. REQUIRED
JAVA
CTL
AUTO-PROPAGATED METADATA

EDIFACTWriter

EDIFACT file

1-n

0-1

x

x

x

x

x

Ports

PORT TYPE
NUMBER
REQUIRED
DESCRIPTION
METADATA

Input

0-N

At least one

Input records to be mapped into the EDIFACT message structure.

Any (each port can have different metadata)

Output

0

x

For port writing.

Metadata

EDIFACTWriter does not propagate metadata.

EDIFACTWriter has no metadata template.

EDIFACTWriter Attributes

ATTRIBUTE
REQ
DESCRIPTION
POSSIBLE VALUES

Basic

File URL

yes

EDIFACT version

Attribute specifying version of EDIFACT message.

EDIFACT message

Attribute specifying type of EDIFACT message. Possible values depend on selected EDIFACT version.

Interchange sender identification

Attribute specifying default identification of EDIFACT interchange sender. When specified, the value is used as default for UNB segment.

Interchange recipient identification

Attribute specifying default identification of EDIFACT interchange recipient. When specified, the value is used as default for UNB segment.

Interchange control reference

Attribute specifying default identification of EDIFACT interchange. When specified, the value is used as default for UNB segment. In EDIFACT the interchange identification should be unique for every interchange exchanged between sender and recipient, therefore this attribute should not be used if multiple interchanges are written at the same time.

Message reference number

Attribute specifying default identification of EDIFACT message. When specified, the value is used as default for UNH segment. In EDIFACT the message identification should be unique for every message exchanged between sender and recipient, therefore this attribute should not be used if multiple messages are written at the same time.

Mapping

k:p

Defines how input data is mapped onto an output EDIFACT message. See Details below.

Mapping URL

k:p

External text file containing the mapping definition.

Advanced

Strict validation

Enables strict validation of the written values, their sizes and data types. Also checks that composite elements are not written in places where only simple elements are allowed. Produces error if any validation check finds a problem.

true (default) | false

Cache size

Cache data records in memory instead of the JDBM’s disk cache (default). Note that while it is possible to set the maximal size of the disk cache, this setting is ignored in case the in-memory cache is used. As a result, an OutOfMemoryError may occur when caching too many data records.

false (default) | true

Sorted input

Tells EDIFACTWriter whether the input data is sorted. Setting the attribute to true declares you want to use the sort order defined in Sort keys, see below.

false (default) | true

Sort keys

COMMIT (default) | ROLLBACK

Max number of records

0-N

Partitioning

Records per file

1-N

Partition key

Partition lookup table

Partition file tag

Number file tag (default) | Key file tag

Partition output fields

Partition unassigned file name

Partition key sorted

false (default) | true

[1] One of these must be specified if EDIFACT version and EDIFACT message are used. If both are specified, Mapping URL has a higher priority.

Details

Input data has to provide all mandatory data required by selected EDIFACT message format. When any mandatory element is missing the mapping editor produces a warning. Type of a message can be specified by EDIFACT version and EDIFACT message properties in the component.

Individual fields of EDIFACT message can be filled by input fields of primitive types such as string or long. Entire subtrees of the target message can be filled by input variant fields. When using variant fields the structure of the input variant must match the schema of the target mapped element, otherwise the EDIFACTWriter will fail at runtime.

Specifying EDIFACT version and EDIFACT message is optional. You can leave both attributes empty, in which case EDIFACTWriter expects a single variant field with entire interchange structure on first input port. Defining a mapping is not possible in this case.

Autofilled segments

EDIFACTWriter automatically fills values for some elements. EDIFACT technical fields such as various segment counters, checksums and timestamps are computed automatically when writing.

These fields are filled automatically, it is not necessary to specify their values in input data:

  • UNB0401 (Interchange header) - Date and time of preparation - Date

  • UNB0402 (Interchange header) - Date and time of preparation - Time

  • UNG0401 (Group header) - Date and time of preparation - Date

  • UNG0402 (Group header) - Date and time of preparation - Time

  • UNT01 (Message trailer) - Number of segments in a message

  • UNT02 (Message trailer) - Message reference number

  • UNE01 (Group trailer) - Group control count

  • UNE02 (Group trailer) - Group reference number

  • UNZ01 (Interchange trailer) - Interchange control count

  • UNZ02 (Interchange trailer) - Interchange control reference

When Mapping attribute is used, additional EDIFACT fields are pre-generated with default values based on current configuration of the component. You can see the pre-generated defaults in the Mapping dialog.

Examples

Mapping different ports on parts of an EDIFACT message format allows to insert multiple repeating segments into one EDIFACT message file.

The example below creates one EDIFACT interchange for each record obtained from port 0 and one AUTHOR message for each record obtained from port 2.

See also

Only one field (byte, cbyte or string) is used. The field name is used in File URL to govern how the output records are processed - see

The target file for the output EDIFACT message. See .

Tells EDIFACTWriter how the input data is sorted, thus enabling streaming. The sort order of fields can be given for each port in a separate tab. Working with Sort keys has been described in .

The maximum number of records written to all output files. See .

The maximum number of records that are written to a single file. See .

The key whose values control the distribution of records among multiple output files. For more information, see .

The ID of a lookup table. The table serves for selecting records which should be written to the output file(s). For more information, see .

By default, output files are numbered. If this attribute is set to Key file tag, output files are named according to the values of Partition key or Partition output fields. For more information, see .

The fields of Partition lookup table whose values serve for naming output file(s). For more information, see .

The name of a file that the unassigned records should be written into (if there are any). If it is not given, the data records whose key values are not contained in Partition lookup table are discarded. For more information, see .

In case partitioning into multiple output files is turned on, all output files are open at once. This could lead to an undesirable memory footprint for many output files (thousands). Moreover, for example unix-based OS usually have a very strict limitation of number of simultaneously open files (1,024) per process. In case you run into one of these limitations, consider sorting the data according a partition key using one of our standard sorting components and set this attribute to true. The partitioning algorithm does not need to keep open all output files, just the last one is open at one time. For more information, see .

EDIFACTWriter receives data from all connected input ports and converts records to EDIFACT message structure based on the mapping you define. You map the input ports and fields in a manner similar to XMLWriter as described in . Finally, the component writes the resulting tree structure of elements to the output: an EDIFACT message file, port or dictionary.

info@primeur.com
X12Writer
Common properties of components
Specific attribute types
Common Properties of Writers
Sort Key
Creating the Mapping - Mapping Ports and Fields
Writing to Output Port
Selecting Output Records
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Partitioning Output into Different Output Files
Supported File URL Formats for Writers