---
id: change/bcapps/9078
type: change
title: "#9078 Bug 624364: Intrastat DE groups detail lines by Country/Region of Origin"
summary: German Intrastat export now groups detail lines by both Tariff Number and Country of Origin to prevent merging lines with the same tariff but different origins and losing origin information.
tier: official
language: en
tags:
  - fix
  - main
  - bc30
  - codeunit intrastatreportdeupgrade
  - codeunit intrastatreportmanagementde
system: inventory
review:
  state: reviewed
  by: opus
  at: "2026-10-08T02:13:36.597Z"
  flags: []
generated:
  at: "2026-10-08T01:26:53.141Z"
  pipeline: 0.2.0
  prompts:
    extract-change: 1
  input_hash: 1711fffec9a3601fcfc36119d37afb5bfbdc795f
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/pull/9078
    title: "microsoft/BCApps#9078: Bug 624364: Intrastat DE groups detail lines by Country/Region of Origin"
    date: "2026-07-07"
    commit: 1711fffec9a3601fcfc36119d37afb5bfbdc795f
    t: null
    quote: null
links:
  learn: []
  objects:
    - object/codeunit/11034-de
    - object/codeunit/11029-de
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes: []
number: 9078
repo: microsoft/BCApps
source_id: bcapps-prs
url: https://github.com/microsoft/BCApps/pull/9078
kind: pr
base_branch: main
major: "30"
merged_at: "2026-07-07T14:35:39Z"
author: alexei-dobriansky
author_type: User
community_contribution: false
labels:
  - "Team: SCM"
change_class: code
change_kind: fix
behavior_change: true
breaking: false
files:
  count: 4
  additions: 46
  deletions: 2
  al: 2
apps:
  - IntrastatDE
objects_touched:
  - key: codeunit/11034
    page: codeunit/11034-de
    type: codeunit
    id: 11034
    name: IntrastatReportDEUpgrade
    app: IntrastatDE
    status: modified
  - key: codeunit/11029
    page: codeunit/11029-de
    type: codeunit
    id: 11029
    name: IntrastatReportManagementDE
    app: IntrastatDE
    status: modified
objects_unjoined: []
obsoletions: []
backports: []
fixes_issues: []
work_items:
  - 624364
systems:
  - inventory
quote: null
joined_against:
  major: "30"
  commit: a4406cfa9e57437fedc49c53c327a199a854491e
---

# #9078 Bug 624364: Intrastat DE groups detail lines by Country/Region of Origin

> German Intrastat export now groups detail lines by both Tariff Number and Country of Origin to prevent merging lines with the same tariff but different origins and losing origin information.

[Pull request](https://github.com/microsoft/BCApps/pull/9078) · merged into `main` (BC30) on 2026-07-07 by alexei-dobriansky · 4 files (+46 -2), 2 AL · fix · tier official · reviewed (checked by Opus)

## What changed

- Added Country/Region of Origin Code (Field ID 24) to detail grouping sets in INTRA-2022-DE data-exchange definition
- Updated both receipt (7-RCPTDETAIL) and shipment (8-SHPTDETAIL) grouping configurations
- Implemented upgrade logic to re-import the corrected definition for existing tenants
- Added test coverage for the data-exchange definition
- Behaviour changes for users or extensions.

## AL objects touched

- [Codeunit 11034 "IntrastatReportDEUpgrade"](../../objects/codeunit/11034-de.md), IntrastatDE (DE layer): modified
- [Codeunit 11029 "IntrastatReportManagementDE"](../../objects/codeunit/11029-de.md), IntrastatDE (DE layer): modified

## Context

- Work items: AB#624364
- Labels: Team: SCM
- Systems: inventory

Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).
