I have a sql table (version 9.3 PostgreSQL) with fields (tour character varying, tourtime int)... I want to write a query like case when tour = 'A' then tourtime = 2 when tour = 'B' then tourtime = 3 else 0 etc..
However i get the error
CASE types integer and boolean cannot be matched
Why is this?