A test you can run to check that the setup below works.
How to run the test
Before you start
Apply Canadian harmonized sales tax rules is Yes in General ledger parameters.
HST dimensions are selected and ranked.
A specific rule and an all-blank fallback rule exist with different sales tax codes, and all codes are in the vendor's Sales tax group and the item's Item sales tax group.
Steps
Create a purchase order line whose distribution matches the specific rule and calculate sales tax.
Change the distribution to dimension values that match no specific rule and recalculate.
Expected result
The first line gets only the specific rule's sales tax codes; after the change it gets the fallback rule's codes.
What should fail
Remove one of the rule's codes from the Item sales tax group: that code is no longer applied even though it is on the rule.