Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
TRACEYSQL
Aged Yak Warrior
594 Posts |
Posted - 2007-11-09 : 09:49:20
|
If i use this and allow cognos or ms access to come in and get data this all works well.(Each maintain a connection in SQL)i see the spid for this against the database snapshot.If i drop and recreate this database the SPID is removed.drop database AdventureWorks_Snapshot1200CREATE DATABASE AdventureWorks_Snapshot1200 ON(NAME = N'AdventureWorks_Data', FILENAME=N'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\AW_1200.ss')AS SNAPSHOT Of AdventureWorksWhen cognos reporting of access database try their report again i get the errorError number 269: DMS-I-INFORMATION, The target database has returned information concerning the 'close cursor' operation.[Microsoft][ODBC SQL Server Driver][DBMSLPCN]ConnectionWrite (send()).DMS-I-CANCELFAILURE, An attempt to cancel the '?' operation has been rejected by the target database.[Microsoft][ODBC SQL Server Driver][DBMSLPCN]General network error. Check your network documentation.Thats because the Original SPID has been removed.....They hit refresh all works another connection has been made.Is there a way to prevent getting this message or maintain the connection when dropping databaseOr an update database snapshot ? |
|
snSQL
Master Smack Fu Yak Hacker
1837 Posts |
Posted - 2007-11-09 : 21:16:35
|
This is probably more of a Cognos question, you'll need to find out how to do some error handling in Cognos. When you remove that database you will kill any connections that have it as the current database.However, you could make it somewhat better by making another database the current database for the connection. To do that, specify a different database in the Initial Catalog parameter in the connection string, and don't change the database with any USE statements. It means you'll have to access tables, stored procedures and other objects using three part names, but that way the Cognos connection will not be killed when you drop the database.Either way, you should have error handling in the app which handles any case when the database or server is unavailable. |
|
|
TRACEYSQL
Aged Yak Warrior
594 Posts |
Posted - 2007-11-10 : 08:12:02
|
Thanks i try find forum for cognos i asked the bi team. Totally agree apps should handle this and not display connection errors. |
|
|
TRACEYSQL
Aged Yak Warrior
594 Posts |
Posted - 2007-11-11 : 18:12:50
|
Re reading this again...inside of cognos use another copy of database i.e db1 - we create the catalog so im not sure how to do it against db1 and it be on SNAPSHOT? i know this is cognos setting but if you have any other notes it be great it not i have a look around. |
|
|
rmiao
Master Smack Fu Yak Hacker
7266 Posts |
Posted - 2007-11-11 : 20:02:08
|
I believe Cognos can answer the question better. |
|
|
|
|
|