No transactions listed #7

Open
opened 2026-04-10 18:50:19 +02:00 by jakob · 1 comment
Owner

The table listing transactions is empty in the transactions view. Even after selecting a "From date" extremely early and logged in as a customer who has transactions in the database

The table listing transactions is empty in the transactions view. Even after selecting a "From date" extremely early and logged in as a customer who has transactions in the database
jakob added the bug label 2026-04-10 18:50:19 +02:00
Collaborator

Investigation Plan:

  1. Check what transactions exist for customer 1846 (id=1) in DB
  2. Verify the transaction_date format in DB (DATETIME vs string)
  3. Debug the transactions query to see if results are returned
  4. Check customer_id linkage in transactions table

The query uses:

  • WHERE customer_id = ? with the customer ID from customers table
  • transaction_date BETWEEN ? AND ? for date filtering

Potential issues:

  • Customer ID mismatch (transactions linked to different customer_id)
  • Date format comparison (string vs DATETIME)
  • Using direct sqlx query vs repository method
**Investigation Plan:** 1. Check what transactions exist for customer 1846 (id=1) in DB 2. Verify the transaction_date format in DB (DATETIME vs string) 3. Debug the transactions query to see if results are returned 4. Check customer_id linkage in transactions table The query uses: - `WHERE customer_id = ?` with the customer ID from customers table - `transaction_date BETWEEN ? AND ?` for date filtering Potential issues: - Customer ID mismatch (transactions linked to different customer_id) - Date format comparison (string vs DATETIME) - Using direct sqlx query vs repository method
Sign in to join this conversation.
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: jakob/rusty-petroleum#7