I'm trying to create a view with a column type as boolean or tinyint(1), but I'm not sure how to customize the datatype. Previously this question was answered by saying, use cast() or convert(). I can't do that here as mysql doesn't allow boolean as an output type.
I've also tried using
if(`mytable`.`mycolumn`=1,TRUE,FALSE) AS myAlias
Unfortunately myAlias in the view is created as a bigint(20)
Here's the similar question I was talking about where casting was suggested. My reputation isn't high enough for me to post a comment there, so I decided to make a separate question. Is it possible to change the datatype of a column in a view?
Thanks