LLBLGen 2.6 final can't connect to SQL 2016

Posts   
 
    
Posts: 35
Joined: 07-Jun-2016
# Posted on: 19-Aug-2021 22:48:02   

I know this might be a long shot but is there a SQL driver that works with LLBLGen 2.6 final and SQL Server 2016?

When I connect to SQL 2012 it connects just fine but with SQL 2016 I get this error:

ExecuteReader: CommandText property has not been initialized

-----[Core exception]-------------------- at System.Data.SqlClient.SqlCommand.ValidateCommand(String method, Boolean async) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) at SD.LLBLGen.Pro.DBDrivers.SqlServer.SqlServerCatalogRetriever.RetrieveSchemas(String connectionString, IDBCatalog catalogToRetrieve, SchemaFetchFlags fetchFlags) at SD.LLBLGen.Pro.DBDrivers.SqlServer.SqlServerDBDriver.PopulateSelectedCatalogs(Hashtable callBacks, Hashtable connectionElements, SchemaFetchFlags fetchFlags, Hashtable properties) at SD.LLBLGen.Pro.Gui.Forms.NewProjectWizard.CreateNewProject()

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39749
Joined: 17-Aug-2003
# Posted on: 20-Aug-2021 08:54:26   

You have to adjust the source of the driver (available on the website after you log in) to make sure it picks the 'default' branch in the switch statements. The v2.6 driver wasn't built that robust that it could deal with future versions, so it can't connect to new databases (it was released in 2008 ).

A newer LLBLGen Pro version also works.

Frans Bouma | Lead developer LLBLGen Pro
Posts: 35
Joined: 07-Jun-2016
# Posted on: 20-Aug-2021 16:15:06   

Are you referring to the Downloads for LLBLGen Pro v2.6 page? Under the Drivers section there's a Drivers package but I don't see where I can pick different branches.

I do have LLBLGen Pro v5.2 as well. Can I upgrade a v2.6 project to 5.2 and still output the VS project as VB.Net?

Edit: I found the upgrade to v5 instructions, I'm going to try that.

Posts: 35
Joined: 07-Jun-2016
# Posted on: 20-Aug-2021 17:56:27   

Edit: I was able to upgrade my project to v5 and was able to generate source code. thanks.