This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
I am trying to follow the "GettingStarted" video but don't get very far due to a problem when dragging tables into the model view. I am running WinXP SP3, VS2008 Net3.5, SQL Server 2008, LightSpeed 2.2 (A collegue with a similar setup did not have this problem.) Below is what appears in the Output window:
Exception while processing Server Explorer drag: System.Data.SqlClient.SqlException: Invalid object name 'sys.key_constraints'. Invalid object name 'sys.tables'. Invalid object name 'sys.schemas'. Invalid object name 'sys.index_columns'. Invalid object name 'sys.columns'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) at System.Data.SqlClient.SqlDataReader.ConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, 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 Mindscape.LightSpeed.Generator.Extraction.SqlServer2005.d__0.MoveNext() at Mindscape.LightSpeed.Generator.Extraction.Provider`1.CreateEntities(TypeModel model, TConnection connection, Boolean pluralise, IList`1 tablesToFullyPopulate) at Mindscape.LightSpeed.Generator.Extraction.Provider`1.ExtractModel(Boolean pluralise, IList`1 tablesToFullyPopulate) at Mindscape.LightSpeed.Generator.Integration.EntityExtractor.PopulateTypeModel(ILightSpeedDataSource connection, IList`1 tableNames, Boolean pluralisedInDatabase) at Mindscape.LightSpeed.Generator.Integration.EntityBuilder.AddTablesToModel(Model model, ILightSpeedDataSource connection, IEnumerable`1 tableNames, IGenerationLog log) at Mindscape.LightSpeed.Generator.Integration.LightSpeedModelDiagram.<>c__DisplayClass4.b__3(DragObject dragObject, IGenerationLog log) at Mindscape.LightSpeed.Generator.Integration.ServerExplorer.IfIsServerExplorerDrag(DragEventArgs e, DragAction action) |
|
|
Could you check that you are definitely connected to a 2008 database? That error is characteristic of a SQL Server 2000 database. If you are using SQL Server 2000, we have added support for this since 2.2 came out and you can get it in the nightly builds, though there are some limitations and we do recommend using 2005 or 2008 if you have the choice. |
|
|
Thanks, I suspected that was the issue and apparently I do have 2000 running. Is this an issue for development only, or would it affect our release software also? |
|
|
If your target database is SQL Server 2000, then yes, your release software will be affected. LightSpeed's SQL Server 2005 provider does use features that are specific to SQL Server 2005, specifically ROW_NUMBER for paging. However, we do now have a SQL Server 2000 provider, which supports most LightSpeed features (but not paging). This includes both runtime and designer support for 2000. To get this, please download the nightly build (you can get the free edition from here, or retail editions from the store; please note the caveat about uninstalling the RTM before installing the nightly). If your target database is SQL Server 2005 or 2008, but you happen
to have SQL Server 2000 instead, then you can create models either in
code or by dragging from the Toolbox instead of the Server Explorer,
and you can use those models on SQL Server 2005 (or indeed any other
database). However, you'll obviously find it easier to test if you're running the same database version as your target database. It is possible to run SQL 2000 and SQL 2005 side by side if you need to keep a SQL 2000 instance around for other applications. |
|
|
Thanks for the info.
I downloaded the 20Oct build and started a new project, but unfortunately I'm still experiencing the same problem. |
|
|
Ah, sorry. At the moment, the designer doesn't auto-detect the version of SQL Server. Click on the design surface, go into the properties window and set Database Provider to SqlServer2000. Then try dragging again. Apologies, I forgot you had to do this little dance... |
|