0

I have the .sdf for SQL Server Compact Edition database of Northwind, I'm trying to attach it to llblgen pro but it refuses to connect, in the 'database drivers' drop down I've selected SQL Server 2000/etc, etc (there is no SQL Server CE in the drop down) and in 'server name' I've put the full path to the database:

C:\Program Files (x86)\Microsoft SQL Server Compact Edition\v3.5\Samples\Northwind.sdf

The error I get when I try to test the connection is:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

LLBLGen Pro version 3.5. Build March 23rd, 2012 -----[Core exception]-------------------- at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Connect(ServerInfo serverInfo, SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject) at System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject) at System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart) at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) at System.Data.SqlClient.SqlConnection.Open() at SD.LLBLGen.Pro.Gui.Controls.WizardPages.MetaDataRetrievalWizard_Step_ConnectionData.TestConnectionData(Boolean showSuccess)

I've also tried adding the sdf to sql server management studio then adding it to llblgen but still no luck...

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
meds
  • 21,699
  • 37
  • 163
  • 314
  • SQL Server CE is **NOT** the same as the "regular" SQL Server. If you don't have any "SQL Server CE" entry in the dropdown, you won't be able to connect. – marc_s Apr 10 '12 at 04:57
  • how can I get SQL CE in the drop down? – meds Apr 10 '12 at 04:59
  • When I Google for "LLBLGen SQL Server CE", [this is the first link that comes up](http://www.llblgen.com/documentation/2.6/compactframeworksupport.htm) - have you had a look at that?? If that doesn't help --> ask LLBLGen Support... – marc_s Apr 10 '12 at 05:15

2 Answers2

1

LLBLGen supports SQL CE database. Please specify the correct compatibility level in .config file:

<add key="SqlServerDQECompatibilityLevel" value="4" />

Please read "DQE Compatibility mode" section in the documentation: http://www.llblgen.com/documentation/3.5/LLBLGen%20Pro%20RTF/Using%20the%20generated%20code/gencode_applicationconfiguration.htm#compatibilitymodesqlserver

0

Turns out the version of LLBLGen Pro I was using does not support .Net Compact Framework (as of V3.0 the stopped supporting it).

meds
  • 21,699
  • 37
  • 163
  • 314