.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

database.Schemas.Contains not valid for SQL 2000

Posted By:      Posted Date: August 31, 2010    Points: 0   Category :Sql Server
database.Schemas.Contains(LoginName) doesn't appear to work with SQL 2000 - is there an alternative method? I'm checking for the existance of the Login and User and droping them if they exist via:   Dim xServer As Server = New Server(ServerName & "\" & Instance) Dim db As New Database(xServer, Database) db = xServer.Databases(Database) If db.Schemas.Contains(LoginName) Then db.Schemas(LoginName).Drop() End If If db.Users.Contains(LoginName) Then db.Users(LoginName).Drop() End If Which errors (Operation not supported on SQL Server 2000.) on db.schemas.contains.

View Complete Post

More Related Resource Links

Metadata: Create a Database Schema Repository with Meta Data Services in SQL Server 2000


SQL Server 2000 Meta Data Services is a repository technology that stores and manages metadata for SQL Server. Instead of building database schemas over and over, Meta Data Services allows you to freeze an entire schema for use in other projects. You can also use these schemas for training, testing, or debugging. In this article, the authors will review the various components of Meta Data Services and show how it can be programmed using a Visual Basic client, XML, and XSLT. They will also show you how to manage and manipulate your metadata by generating a simple database schema using a SQL Server repository.

Alok Mehta and Ricardo Rodriguez

MSDN Magazine May 2003

Restoring a 2008 Database in a 2000 Database.

I've been trying to restore a SQL Server 2008 database in SQL Server 2000 and it seems impossible. Does anyone know how to do it or maybe will be able to point me in the right direction?

"The Database Engine instance you selected is not valid for this edition of Reporting Services" erro

Hi there, I have developed some reports using Visual Studio and everything worked fine in the office. Now I'm trying to deploy them on my customer PCs but this process keeps failing. These reports can be built and even previewed within Visual Studio but they cannot be deployed. Here is the error message I get: ----------------------------------------- The feature: "The Database Engine instance you selected is not valid for this edition of Reporting Services. The Database Engine does not meet edition requirements for report data sources or the report server database." is not supported in this edition of reporting services. ---------------------------------------- The versions of the software on my customer machines are: SQL Server Enterprise 9.0.3282 SQL Server 2005 Management Studio 9.00.4035 SQL Server 2005 Reporting Services Designers 9.00.4035.00 Visual Studio 2005 8.0.50727.42 I believe that changing the edition of the Reporting Services from Designers to Enterprise should fix the deployment error but I did not find a way or setup files to do so. Many thanks in advance for your help!

migration MSDE 2000 SP3 database to SQL 2005 SP3: low performance on 2005 Express

I've detach MSDE 2000 SP3 database. I've attach into SQL 2005 Express SP3 and SQL 2005 Standard SP3. I've change compatibility level to 90. I've update statistics with EXEC sp_MSforeachtable @command1="UPDATE STATISTICS ? WITH FULLSCAN" The execution time of a TSQL into the same hardware (1 CPU, Quad Core) are: SQL 2005 Express SP3: 20" SQL 2005 Standard SP3: 0" The execution plan is different. Why?

SQL 2000 migrating older data to a different database

I've a sql server 2000 database, and now its size has increased tremendously. it is roughly 20 GB. this db contains data since last 4 years i.e. 2007. so i would like to create a new db with same schema, move all the data for the year 2007-2008 from the existing database to this newly created db. and then continue to use the exisitng db with my application.  now in my application, there will be an option to switch db, if i select the newly created db, it will fetch the data for year 2007-2008. if i select the existing db, it will be working with the current data.   please suggest what is the best approah to work on this. my application is a vb.net desktop application with framework 2.0. please suggest thanks shruti  

Migration / Export of Analysis Services 2000 database without affecting the source database

Hi! I´m am currently initating a migration of a 300GB Analysis Services database containing approx 50+ cubes. My issue is that the database is somewhat critical, and I just want to get a couple of answers and feedback before i press Go. My plan is to use the "Analysis Services Migration Wizard" to migrate the database to a new (test environment) server. Q1: I just want to migrate the structure, the metadata, is this what the migration wizard does? I don´t have 300GB disk space at the test server to accomodate all the data. We will start off with just a subset Q2: Since the data is 300GB+, it might take a very long time using the migration wizard. If that is the case, can I make a copy of the database in analysis manager 2000 and paste it with a different name, and the migrate this, empty, database? Would you see any trouble with this approach? Any other thoughts on this, somewhat massive, migration project? How would you do it? The most important this is that the old database cannot be touched, since this would mean a reprocess of 300GB data, on a server from the nineties... Cheers,

0x80040154 error processing a cube from SQL Server 2008 R2 x64 database engine to OLAP Server 2000 x


I recently upgrade from SQL Server 2000 x32 to SQLServer 2008 R2 x64 but only the database engine not the Analysis Server, I used to use this code to proces the cubes.


but now it do not  work more with the error:
Error at create server:
Error      Source                    Description          HelpFile HelpID
---------- ------------------------- -------------------- -------- -----------
0x80040154 ODSOLE Extended Procedure  Clase no registrada NULL     0

(1 row(s) affected)

I found this article:

It means that I can not process the cube using the same method any more ?

cannot restore sql 2000 database in sql server 2005 in windows 7


cannot restore the databse made in sql server 2000 in sql server 2005 in windows 7 with thw following error message

TITLE: Microsoft SQL Server Management Studio Express

Restore failed for Server 'KHURANA\SQLEXPRESS'.  (Microsoft.SqlServer.Express.Smo)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.3042.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Restore+Server&LinkId=20476


System.Data.SqlClient.SqlError: The media set has 2 media families but only 1 are provided. All members must be provided. (Microsoft.SqlServer.Express.Smo)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.3042.00&LinkId=20476



plz help me out

Find unused objects in a SQL Server 2000 database


Hello All,

I want to know all the objects in a database which are not been used from a long period (Unused in the sense not executed from a long period; example procedures.). Could anyone show be the way of how to get it done.

Thanks in advance.

Pavan Kokkula Infosys Technologies Limited.

Windows 7 connecting to SQL server 2000 database

Is is possible to connect to a SQL Server 2000 database (running on a windows 2003 server) from a Windows 7 client machine?

Master Database on a MS SQL 2000 cluster


Hi guys

I am have a cluster db at the moment. I noticed that the attached drive was playing up - i.e. backups would not transfer unto (just a simple example).


I took the disk offline and online again. But when trying to start up the SQL Server in the Cluster Admin tool, I get the following error in the logs:

Starting up database 'master'.
Error: 5172, Severity: 16, State: 15.
Stack Overflow Dump not possible - Exception c00000fd E at 0x00409FCA

So basically from the looks of it, the master db is gone. What would be the suggested / advisable / best practise methods to restore / rebuild the master db in a clustered environment?

Just as some extra info: for whatever reason, I do not have the master db backup but I have the backup for the other dbs residing on this SQL server. There might be a possibility that the other dbs are also corrupted - but it's not an issue.


I guess I would like to hear what the quickest method is to rebuild the master and 'reattach' the db if possible. I am new to this so I am actually learning to swim when I am 'drowning' :P


Thank you in advance


Cross database object dependency in SQL Server 2000

Is there a way to figure out cross database object dependency in sql server 2000? (for ex: finding all the objects that a view refers which may reside in the same or different database)

Scheduling ssis package database 2000


Hi Team,

can i schedule a ssis package which is developed on 2000 database?

I have a sql server 2000 server and i am accessing this database using 2005 in another machine and developed a ssis package can i schedule this package?



Failed: Content database with modified database Schemas


After Applying the MOSS 2007 SP2 and WSS3.0 SP2,

I run command: stsadm -o preupgradecheck in administrator mode command prompt.

the result came out with errors and the report noted that below error message:

Failed: Content database with modified database Schemas

Please advise.


Script SQLServer - 2000 database


Hi Gurus,

I need your advice, how to go about the following task which i need to do

1) Create SQLSERVER 2000 database creation script. This will have script for all objects in database.

2) Update the header of each sql files based on the template provided.

for task 1 i can create the sql scripts using enterpirse console for sqlserver. Database have lot of indexes and table. how to find the logical sequence the sql scripts(with out hit and trial) ?

for task 2 do you know any documentaion utility  which can apply header template to each database object sql script ?




If this answer solves your problem, please check Mark as Answered. If this answer helps, please click the Vote as Helpful button. Cheers, Rajender Saini Aditi Enterprise Solutions - Partnering Innovation | www.aditi.com

Database tables + procedures + schemas protection



I'm using a secure tsql connection to tsql database whith a tsql user (db owner of the database). In the Web.config and the App.config we can see the username and the login in the connectionstring.

So, if anyone have access to these files could connect to sql server throu this user and have acess to the database.

Is there a way to protect the access to the database ?


SQL Server 2000 Database in "single user mode"


Hi all,

I've an old production database server with SQL Server 2000 SP4, that runs from 6 years. Now sometimes I find that the production database goes in "single user mode". Why? My error logs don't help me.

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend