the recordset should lookup the orders table, and filter the orderUserID usingthe session variable of the logged in user.
the recordset will have a variable named $totalRows_<recordsetName> where <recordsetName> is the name of the recordset.
use the set session value behavior to store the $totalRows_<recordsetName> variable.
in the discount, use the Based on session variable value trigger to trigger the discount if the session is greater than 5.