Skip to Content
Nov 10, 2020 at 11:22 PM

Crystal Reports 2020 - SQL Syntax Error


I recently upgraded from Crystal Reports 2013 (version 14.1.x) to 2020 (version 14.3.x). One of the reports I run doesn’t seem to work in Crystal Reports 2020. I am getting the error “SQL Syntax error” when I try refreshing the report. The exact same .rpt file refreshes fine in Crystal Reports 2013.

The SQL query generated in Crystal Reports 2020 is syntactically correct (I've ran it through SQL syntax checkers). While reviewing the SQL query generated in CR 2020 and CR 2013, I noticed the FROM clause generated in CR 2020 has all tables joined with INNER JOIN whereas the SQL query generated in CR 2013 does not.

I started looking into this a bit more and did come across this post from 2010. The post is for Crystal Reports XI (version 11.5). It mentions a registry key and "SQLServerJoinBuilder"="adbc" (was this a typo for "odbc"?). I am almost positive this should resolve my issue, but that post doesn't have much details.

I also found KB 1217820 - Registry settings to configure how the SQL Query is generated in Crystal Reports. It does provide more details, but I just can't seem to figure out what registry key I need. Since I am using Crystal Reports 2020, I do know I need:

[HKEY_CURRENT_USER\SOFTWARE\SAP BusinessObjects\Suite XI 4.0\Crystal Reports\Database\QueryBuilder\JoinBuilder]

I did have to create all the keys starting from 'Database'. After this, steps 7 and 8 are unclear to me. Do I need to add the string value SQLServerJoinBuilder and then set it's value to match my ODBC Driver File Name from step 4? I am using Rocket Software's U2 ODBC Drivers and I see "U2ODBC.DLL" in the file name. Should I create the string key and values shown below?

 SQLServerJoinBuilder = U2ODBC 

If that's the case, this isn't working for me. Or am I supposed to create the string key U2ODBCJoinBuilder? If so, what value should it be set to?

I've tried many different things with this registry path, but nothing seems to resolve my issue. Am I on the right track? Is this what I need to resolve my issue? What am I missing with these registry keys/values?