home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / datatl25.zip / DCTDSGN.Z / EWSQDOIG.QRY < prev    next >
Text File  |  1997-09-12  |  1KB  |  38 lines

  1. #NAME#
  2. DA_OracleIndexGlossary
  3. #DESCRIPTION#
  4. The index glossary query returns name of the indexed table and the columns used by the index referenced by the specified name.   
  5.  
  6. View type:  DAQOracleIndex
  7.  
  8. Modifications:
  9. Change the search criteria of the index name using the = (equals), IN or LIKE elements in the SQL WHERE clause.  The WHERE clause may be changed to locate all indexes which match the specified characteristics. In order to provide unique Oracle index names, the name has the format <>RelSystem:Schema:::IndexName<variation:revision>.
  10.  
  11. To find all DB2/390 indexes which have a specific simple name, use the LIKE clause with % as either of the first two qualifiers.  To speed up your query, use % to include the colons and separators.  For example, if you want all indexes starting "CUST", specify LIKE '%::CUST%'.
  12.                                 
  13.  
  14. #MODIFIED#
  15.  
  16. #VERSION#
  17.  
  18. #SQL STATEMENT#
  19. SELECT DISTINCT
  20.   i.oracleIndex,
  21.   i."schema",
  22.   i.inRelationalSystem..relationalSystem,
  23.   i.inPhysicalDesign..oraclePhysicalDesign,
  24.   i.forTable..oracleTable,
  25.   k.keyColumnName,
  26.   k.ascDescFlag,
  27.   i.uniqueFlag,
  28.   p.lastUpdate
  29. FROM
  30.   DAQOracleIndex i,
  31.   (i.usesKeyDefinition) k,
  32.   PartView p
  33. WHERE
  34.   i.oracleIndex LIKE '<>%' AND
  35.   i.oracleIndex=p.baseName
  36. ORDER BY
  37.   i.oracleIndex
  38.