Material Transfer - Missing transactions from JE
🤔 Problem
User creates a JE with type “Inventory“ with GL Distribution records containing inventory items. See example:

When running “Generate GL Material Transfer“ there should be a transfer created. When looking in the Transaction Inquiry it says “Has Material Transfer“ as True, but when searching Item Code and Location To (Cost Center) with Accounting Date from JE there aren’t any in Material Transfer Lines.


The root cause is still unknown and issue has been reported here → WEMAIN-24730
🌱 Solution
The script below will be able to identify which Transaction Inquiry lines that are missing in Material Transfer but have (journal_entries.has_material_transfer = true).
select distinct je.voucher_number
from gl_transactions glt
left join material_transfer_items mti
on glt.item_catalog_id = mti.item_catalog_id
and isnull(glt.serial_number, '') = isnull(mti.serial_number, '')
and glt.coa_account_id in (mti.from_chart_of_account_id, mti.to_chart_of_account_id)
and glt.activity_date = mti.transfer_date
left join journal_entries je
on je.id = glt.object_id and je.journal_entry_type_id = 8
where glt.has_material_transfer = 1
and glt.type_of = 'je'
and glt.item_catalog_id is not null
and mti.id is null
and je.source = 'Direct Entry'
and je.status = 'Posted'
-- and je.accounting_date >= '2025-01-01' Include accounting period
From there you can update them to False or from the app copy the JE and run Material Transfer, or manually create a Material Transfer for the items.