Query used by the PAHT service to get the tickets for printing from the database

 

I find the following helpful for troubleshooting PAHT issues so posting here as may also be a help to others.

 

This is the query used by the PAHT service to get the tickets for printing from the database:

 

exec wp_get_orders_for_delivery @use_primary_email=default,@delivery_method=N'2'