Take a result set and cast a column as BOOLEAN - the field MUST be Boolean
Posted on 2008-09-30
I have a database table in Firebird which doesn't have a Boolean datatype, so the fiels is actually of type VARCHAR(5) and the values are all "True" and "False" (strings).
Unfortunately my application uses a 3rd party component which no longer works now that the fields aren't Boolean - I think it HAS TO MAP to Boolean fields.
I've already spent about 5 hours going through hundreds of lines of code trying to rewire it to accept the VARCHAR fields - WHEN I HAD AN IDEA - couldn't I have some kind of a temporary DataSet where I could pump the resultset so that the column is BOOLEAN?
The only way that *I* know how to do this would be to set up a table in ANOTHER database like MSaccess or BDE and pump the data there - do you know of a better way?