Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SMO behaviour differneces between SQL2000 and SQL2005
Message
De
27/09/2007 10:57:48
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Titre:
SMO behaviour differneces between SQL2000 and SQL2005
Divers
Thread ID:
01257190
Message ID:
01257190
Vues:
61
Hi,

Using SMO to gather information on various SQL servers. The following code snippet takes *significantly* longer to complete when run against a SQL2005 Express server compared to a SQL2000 server:
Server srv = new Server("xxx")
foreach (Database db in  srv.Databases)
{
    if (! db.IsSystemObject)
       //do something
}
Accessing the 'db.IsSystemOject' property is slow and seems to requery the server if it's SQL2005; the SQL2000 response if virtually instantaneous. Any way of improving the performance?
Regards,
Viv
Répondre
Fil
Voir

Click here to load this message in the networking platform