Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DMO Index Type Woes
Message
From
19/03/2002 10:20:26
 
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Other
Title:
DMO Index Type Woes
Miscellaneous
Thread ID:
00634464
Message ID:
00634464
Views:
49
Hi

I'm trying to use the type property of the index object to determine what type of indexes I have against my tables in SQL Server.

However, the values I'm getting returned from this property seem to be excessive high and don't appear to be in the user manual (SQL Books Online)

if I create a simple index using t-sql eg ;

CREATE INDEX TEST ON MyTable (MyColumn)

when i use my dmo program to return the type property values for this index I'm getting 2097152 back as the return value.

Does anybody know what this figure is as it doesn't seem to equate to any value in the documentation?

I'm using sql server 7.0 and my dmo access is via Microsoft Visual Foxpro 6.0. here's a example of the code I'm using , (this isn't production code btw)


oSQLServer = CREATEOBJECT("SQLDMO.SQLServer")
oSQLServer.CONNECT("MyPC","MyUser","MyPassword")
oDatabase = oSQLServer.DATABASES.ITEM("MyDataBase")
oTables = CREATEOBJECT("SQLDMO.Table")
oTables.NAME = 'MyTable'

FOR lnTagLoop = 1 TO oDatabase.TABLES('MyTable').INDEXES.COUNT
? oDatabase.TABLES('MyTable').INDEXES(lnTagLoop).NAME
? oDatabase.TABLES('MyTable').INDEXES(lnTagLoop).TYPE
ENDFOR

Anybody got any ideas?

Thanks, Mark
Next
Reply
Map
View

Click here to load this message in the networking platform