Available Loyalty Points Showing 0 Quantity

Available Loyalty Points Showing 0 Quantity

Environment: 

iVend 6.6 7989 patch

Problem Statement: 

The available loyalty points are showing 0 quantity for some customers.

Symptoms:

--Customer having some available points e.g 200 points
--user performs manual adjustment of 300 points thus gets the value in negatives 
--The awarded points are showing as positive, but the expired points are showing greater than the awarded points.
--The available points column will not show the correct value until the negative awarded points are balanced.

Resolution:

Manually adjust the points or redeem the points to balance the negative awarded points.
Shorten the points expiry days to prevent the points from expiring before they can be used.
SQL Query to Fetch List of Customers with Negative Points:

select AvailablePoints, LoyaltyId, * from LoyLoyaltyCardInformation
inner join LoyPointsSummary ON LoyLoyaltyCardInformation.LoyaltyCardInformationKey = LoyPointsSummary.CustomerKey
where LoyPointsSummary.AvailablePoints < 0
order by LoyPointsSummary.AvailablePoints
 
Recommendations:NA