Skip to main content

Electronics Company: Case Study

Electronics manufacturers and distributors trade in structured messages. Purchase orders, invoices, dispatch notices and stock updates travel between suppliers, warehouses and retailers as EDI files and XML feeds, and somebody has to read them when something goes wrong. This case study follows an electronics company in the UK that uses TextPipe to make those files readable, comparable and reusable. The scenario reflects the way the company's eCommerce team described its work to us, and the figures are typical of what similar customers report.

The client

The company supplies electronic components and finished goods to trade and retail customers across Europe. Its eCommerce team receives orders and stock data from partners every day, and sends invoices and shipping notices back in the same formats.

The challenge

Most partner files arrived as EDI messages. An EDI file is often one very long string, with an apostrophe (') marking the end of every segment instead of a line break. Opened in a text editor, a 5 MB order file looks like a single line, and finding one segment means scrolling sideways through thousands of characters. When an order failed validation, the project manager had to read that file to find out why.

Other problems came from large flat files. The team sometimes needed to compare two multi-hundred-megabyte extracts line by line and check specific character positions, but ordinary editors either refused to open files that size or ran out of memory. A third problem appeared during a temporary integration project: business data was locked inside XML messages, and the team had no budget for a full XML toolchain to extract it.

TextPipe is definitely a very handy tool, and combined with the BOXER text editor it is a formidable force.

- eCommerce Project Manager

The solution

The team built a small library of saved TextPipe filter lists, one for each recurring job:

  1. Readable EDI. A filter inserts a carriage return and line feed after every segment terminator ('), so each segment sits on its own line. The file can then be read, searched and compared in any editor. The change affects only the layout, so the result can be used for reference without altering what the partner sent.
  2. Column checks on huge files. TextPipe extracts only the lines the team needs from very large files, then deletes the columns that are not part of the check. What remains is small enough to compare by character position. TextPipe reads files as a stream, so size is not a limit. See sorting and processing large files for the same approach.
  3. Business data from XML. Once the team mastered filtering, they used TextPipe to pull order numbers, part codes, quantities and dates out of XML messages and write them as comma-delimited rows that the legacy stock system could import.
  4. Difficult one-off jobs. When partners sent data in an unexpected layout, the team combined filters and pattern matching to reshape it, rather than waiting for a developer. In the project manager's words, TextPipe tackles problems that look impossible.

The results

  • Diagnosis time: reading a failed EDI order dropped from roughly half an hour of scrolling to a few minutes, because every segment was on its own line.
  • File size: comparisons of files with millions of lines ran in minutes instead of being impossible in a desktop editor.
  • No custom code: the XML extraction bridge was built and changed by the business team without a developer, and the saved filter lists were re-run from the command line each night.
  • Consistency: because the same filter list handled every file, two people processing the same order produced identical output.

Beyond data files: documents

Electronics companies also maintain large sets of Word documents, such as datasheets, quality procedures, warranty statements and compliance declarations. When a product code, address or standard changes, WordPipe can apply the change to every document in one batch, which keeps the paperwork in step with the data feeds. See, for example, how to update labeling and disclaimers and replace a company name across all Word documents.

Related reading

The solution pages on data conversion and systems integration describe the general approach. For other industries see the industrial, banking and finance and health and medical case studies.

See also: Testimonials and Customer Uses for TextPipe Pro