Hi, while I was writing this, I solved the issue myself, but I am submitting the text anyway, since there is still an open question.
My problem was: I am getting a data convesion error without specification on the column/data just as follows: "Data conversion error converting ; SQL statement: ... " then the SQL follows. Some background infos: - I am running H2 with an embedded database - I am getting the error with version 1.4.x (also the most recent) - I am getting NO error with 1.2 - I am getting the error while querying a SELECT with LEFT JOINs - BUT: only, if the LEFT JOIN is empty, meaning if the joined tables do not contain relatable content - the query is run from a swing application not in the AWT thread but in a different thread - if I run the same query on the same database using a small test class, the query performs without error - I am getting the error using either mvstore or pagestore I downloaded the H2 source and tried to follow, where the exception is thrown, and it's somewhere in the Prepared.query() method. I can't pinpoint the exact line, because the debugger does not show the correct lines (although I did a clean&build). I just pinpointed the problematic select field: SELECT ... ,IFNULL(ele.number,'') || '.' || IFNULL(obs.number,'') AS fullnumber ... ... this line is concatenating two fields, the second (obs.number) is null, if the left join is empty. I found the changelog not for 1.4.192: The function IFNULL did not always return the result in the right data type. The number fields are of type BIGINT ... there might be a concusion due to mixing bigint fields with string results if the IFNULL returns true... It is working perfectly with the select specified as ,IFNULL(ele.number,0) || '.' || IFNULL(obs.number,0) AS fullnumber But then: why does it work with the small test class? Thanks, Hannes -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/h2-database. For more options, visit https://groups.google.com/d/optout.
