Payment Table

This dataset displays a chronological list of all payments applied to a ticket. Tickets with multiple payments will see the payment amounts split into multiple rows, however, they will share the same Ticket ID.

Dataset ID: 9a62faf2-7147-4731-87c5-327dfb9598a4

Unique Composite Key(s): dateclosed, storeid, paymentid

Datetime Dataset Last Updated: last_retrieved_timestamp

Incremental Load Logic: Use the column dateclosed as data appends per new payment completed

*Pull Previous Day - Data-Raw Append Example:

{"sql": "SELECT * FROM table WHERE date(dateclosed) = date(date_add(now(), INTERVAL -1 day)) "}

*Pull Previous Successful Update - Data-Raw Append Example:

  • stored_last_update_datetime is your stored datetime for last successful data pull

TIP: As a best practice, we recommend that you save the timestamp for each of your dataset pulls as 'stored_last_update_datetime'. Note that this value is not saved in our datasets, but is a suggestion.

Column NameDefinitionExample Output
payment_dateDate–Time Payment Was Accepted2017-11-14T15:47:57
paymentidUnique Payment IDUnique Payment IDff8081815fba6765015fbceea72f0093
paymentnamePayment Name (Cash, Cashless ATM, CHeck, Check Sales, Credit Card, Custom, Debit Card, Integrated ATM, Points, Rewards, cheque, external api)Cash
originalamountAmount Paid326.58
changeamountChange Received (Original Amount - Gross Receipts Paid)0.0
grossreceiptspaidTicket Total326.58
percent_of_ticketnull""
paymentfeeFee associated with the payment1.0
ticketidUnique Ticket ID (Non customer facing)ff8081815fba6765015fbceb1695007b
ticketalphanumUnique Alphanumeric ID (Customer Facing)WE4D20L
ticketstatusCurrent status of the ticket associated with the payment.COMPLETED
dateclosedDate ticket closed2017-11-14
timeclosedDate–Time ticket closed1970-01-01T15:47:57
paymenttypePayment Type (Cash, Cash Refund, Cashless ATM, Cashless ATM Refund, Check, Check Refund, Check Sales, Check Sales Refund, Credit Card, Credit Card Refund, Custom, Debit Card, Debit Card Refund, Integrated ATM, Points, Points Refund, Rewards, Rewards Refund, cheque, externalapi)Cash Refund
customertypeCustomer Type (MEDICAL-MMID, MEDICAL-REGULAR, ADULT-USE)MEDICAL-REGULAR
seconds_to_paymentSeconds from ticket creation to payment of ticket233.0
customergroupsCustomer GroupLOCALS
dateopenDate–Time ticket was created2017-11-14T00:00:00
timeopenedDate–Time ticket was created2019-09-05T15:44:04
datelastmodifiedDate–Time ticket was last modified2019-09-05T00:00:00
timelastmodifiedDate–Time ticket was last modified2019-09-05T02:52:50
datepaymentprocessedDate–Time ticket was last modified2017-11-14T00:00:00
timepaymentprocessedDate–Time ticket was last modified1970-01-01T15:47:57
authcodeAuthorization CodeN/A
refcodeReference CodeN/A
ticketlineidnull""
metrcreceiptMetrc Sales ID""
activitynullDELIVERY
cashierCashierDREW
approverCashier ApproverDREW
documentidDocument IDLIC3660826
ageCustomer Age36
cityCustomer CityWASHINGTON
zipCustomer Zip74555
genderCustomer GenderF
report_last_updatedDate the report was last updated2020-02-10T02:10:20
customer_uuidCustomer Unique ID88deb6b9-5251-3853-b73e-20af025d4528
storeidStore ID230
datalake_dateDate that a store was added to the datalake2020-02-19
week_yearYear - Week2017-46
last_retrieved_timestampthe DateTime we last retrieved data from SellTreez2021-06-09T14:18:30