I hope someone can explains this puzzling behavior. The code below was taken from the book, and it works as given, but when I remove the "yes_or_no" condition from the field list parameters it causes a KeyError('id') error, and I don't understand why.
condition = db.person.name.startswith('B')
yes_or_no = condition.case('Yes', 'No')
## the two select examples above works as expected
This last example in red throws a KeyError('id') error when trying to name specific fields, but works fine when returning ALL fields, or when a condition is specified.