0

I'm trying to make a composite key using some of SQLite's functions but the columns 'newdate' and 'newckey' and appearing blank when I run the query. Any advice?

SELECT *,
       (repeat||date) as 'ckey', 
       (repeat||newdate) as 'newckey' 
FROM (SELECT transactions.id,
             transactions.repeat,
             transactions.date, 
             datetime(transactions.date,'+'||repeattransactions.interval||' days') 
                   AS 'newdate' 
      FROM transactions, repeattransactions 
      WHERE transactions.repeat = repeattransactions.id
     )
Josh
  • 3,445
  • 5
  • 37
  • 55

1 Answers1

0

Nothing wrong with the SQL itself, the dates were stored in the wrong format, including the local timezone info

Josh
  • 3,445
  • 5
  • 37
  • 55