| Home  | Casa  | Hardware  | Networking  | Programmazione  | Software  | Domanda  | Sistemi  |   
software  
  • Adobe Illustrator

  • Software di animazione

  • Antivirus Software

  • Software Audio

  • Backup dei dati

  • masterizzare CD

  • masterizzare DVD

  • Compressione dei dati

  • Software Database

  • Desktop Publishing

  • Desktop Video

  • Digital Video Software

  • Drupal

  • Software didattico

  • ingegneria del Software

  • Tipi di estensione di file

  • Financial Software

  • Freeware, Shareware & Abandonware

  • GIMP

  • Graphics Software

  • Software Home Recording

  • Microsoft Access

  • Microsoft Excel

  • Microsoft Publisher

  • Microsoft Word

  • Aprire Source Code

  • Altro Software per computer

  • Giochi per PC

  • Photoshop

  • Portable Document Format

  • PowerPoint

  • presentazione Software

  • produttività Software

  • Quicktime

  • Gestione Desktop remoto

  • SQL Server

  • Skype

  • Software versioni Beta

  • Consulenti Software

  • Società di sviluppo software

  • Software Licensing

  • Fogli di calcolo

  • Software Preparazione Tax

  • Software Utility

  • Web Clip Art

  • Windows Media Player

  • Word Processing Software
  •  
    Conoscenza Informatica >> software >> SQL Server >> Content
    Come trovare un indice non utilizzato in SQL Server
    Le applicazioni di database rispondono lentamente alle query degli utenti se ci sono gli indici dei database utilizzati. Quando un database viene utilizzato per ottenere i risultati della query , l'indice viene aggiornato con le modifiche apportate ai dati della tabella del database . Gli indici inutilizzati prendere ulteriore tempo per aggiornare , provocando una risposta lenta per le applicazioni dell'utente . Software di Microsoft SQL Server consente di determinare quanto spesso si utilizzano gli indici per migliorare le prestazioni dell'applicazione . Istruzioni
    1

    Fare clic su " Start" di Windows e quindi fare clic su
    2

    Aggiungere le seguenti istruzioni SQL nella finestra aperta "Microsoft SQL Management Console . " :

    - . Creare la struttura delle tabelle richieste

    SELECT TOP 1

    DatabaseName = DB_NAME ( ) per

    , TableName = OBJECT_NAME ( s. [ object_id ] ) per

    , IndexName = i.name

    , user_updates

    , system_updates

    INTO # TempUnusedIndexes

    DA sys.dm_db_index_usage_stats s
    < p > INNER JOIN sys.indexes i ON s . [ object_id ] = i. [ object_id ]

    E s.index_id = i.index_id

    DOVE s.database_id = DB_ID ( ) per

    E OBJECTPROPERTY ( s. [ object_id ] , ' IsMsShipped ') = 0

    E user_seeks = 0

    E user_scans = 0

    E user_lookups = 0 < br . . >

    E s [ object_id ] = -999 - valore fittizio per ottenere la struttura della tabella

    ;

    - loop attorno a tutti i database sul server
    < . UTILIZZO p > EXEC sp_msforeachdb ' [ ? ] ; .

    - tabella esiste già

    INSERT INTO # TempUnusedIndexes

    SELECT TOP 10

    DatabaseName = DB_NAME ( ) per

    , TableName = OBJECT_NAME ( s. [ object_id ] ) per

    , IndexName = i.name

    , user_updates

    , system_updates

    DA sys.dm_db_index_usage_stats s

    INNER JOIN sys.indexes i ON s . [ object_id ] = i. [ object_id ]

    E s.index_id = i.index_id
    < p > DOVE s.database_id = DB_ID ( ) per

    E OBJECTPROPERTY ( s. [ object_id ] , '' IsMsShipped '' ) = 0

    E user_seeks = 0

    E user_scans = 0

    E user_lookups = 0

    ; .

    - selezionare i record

    SELECT TOP 10 * FROM # TempUnusedIndexes ORDER BY [ user_updates ]

    DECR

    DROP TABLE # TempUnusedIndexes
    3

    Fare clic su " File" e quindi fare clic su "Salva" per salvare la procedura nel database SQL . < br >

    Previous :

    next :
      Articoli Correlati
    ·Come creare un server Web App New Utilizzando Kylix SQL…
    ·Come inserire in SQL Server 2008 
    ·Outlook Errore fatale: Microsoft ODBC SQL Server Driver…
    ·SQL Server Express 2005 X64 Servizio Requisiti Level Pa…
    ·Come utilizzare i controlli di iscrizione privo di SQL …
    ·DTS di SQL Server Tutorial 
    ·Come creare una tabella partizionata Server 2005 SQL 
    ·Come impostare il valore predefinito Directory SQL Serv…
    ·Come installare SQL Server Express 2005 e AdventureWork…
    ·Come ripristinare un database di SQL da un file MDF 
      Articoli in evidenza
    ·Perché quando ho ridimensionare una foto in Photoshop …
    ·Come ottenere più opzioni di pubblicazione per Windows…
    ·Makeup Designer 
    ·Come utilizzare un account GL in QuickBooks 
    ·Come condividere Presentazioni PowerPoint Online 
    ·Come creare una pagina di login con Adobe Dreamweaver C…
    ·Come fare un modello di Paisley in Photoshop 
    ·Come Hack Puzzle Pirates 
    ·Come fare Cartoni animati su un PC 
    ·Come eliminare Temporary Internet File Recovery 
    Copyright © Conoscenza Informatica http://it.wingwit.com