كيف يمكن تصحيح الفروقات بين المدين والدائن وإغلاق الفروقات التي نتجت من القيود الغير متزنة حيث أنني كنت أسمح بفرق بسيط بينهما؟

Viewed 0

بدأ العميل العمل و سمح بوجود فرق نصف جنيه أو اقل بين المدين و الدائن في السندات و هو الان يريد ان يقوم بتصحيح هذه السندات و اغلاق هذا الفرق فيها (بعد ان جعل الفرق لا يزيد عن قرش واحد)، فكيف يمكن عمل هذا التصحيح؟


Originally posted at https://answers.namasoft.com/question/615/ on 2019-01-06.

1 Answers

يمكنك استعمال الاستعلام التالي لحصر السندات التي بها فروقات:

select originType,originId,originCode,valueDate,SUM(creditLocalAmount) cr,SUM(debitLocalAmount) dr from LedgerTransLine group by originType,originId,originCode,valueDate
having ABS(SUM(creditLocalAmount)-SUM(debitLocalAmount))>0.0
order by valueDate

Originally posted at https://answers.namasoft.com/question/615/ on 2019-01-06.