| 3 |
"query": "\n INSERT INTO transactions (\n buyer_id, seller_id, item_id, amount_cents, platform_fee_cents,\n stripe_checkout_session_id, status, completed_at,\n item_title, seller_username, share_contact,\n guest_email, claim_token, download_token\n )\n VALUES ($1, $2, $3, 0, 0, $4, 'completed', NOW(), $5, $6, false, $7, $8, $9)\n ON CONFLICT (guest_email, item_id) WHERE status = 'completed' AND guest_email IS NOT NULL DO NOTHING\n ", |