• p.panneerselvam (2/12/2013)


    Execution plan

    Cost

    select 0%

    Parallelism(Gather Streams) 0%

    Sort(Distinct Sort) 0%

    Parallelism(Repartition Streams) 0%

    Hash Match(Partial Aggregate) 3%

    Compute Scalar 0%

    Clustered Index Scan[tblGLJnlEntrySum].tblGLJnlEntrySum_PK 97%

    Inaddition i am getting message like below

    /*

    Missing Index Details

    The Query Processor estimates that implementing the following index could improve the query cost by 97.4146%.

    */

    /*

    CREATE NONCLUSTERED INDEX [<Name of Missing Index, sysname,>]

    ON [dbo].[tblGLJnlEntrySum] ([DivCode])

    INCLUDE ([glPeriodYear],[glPeriodMonth])

    */

    so is that means that i have to create suc index mentioned above?

    The suggested index should improve your query yes. At the moment, SQL Server is having to scan the entire table looking for records where divCode = @vsDivCode. With the new index and included columns the scan should become an index seek on the new indexed column.

    ---------------------------------------------------------

    It takes a minimal capacity for rational thought to see that the corporate 'free press' is a structurally irrational and biased, and extremely violent, system of elite propaganda.
    David Edwards - Media lens[/url]

    Society has varying and conflicting interests; what is called objectivity is the disguise of one of these interests - that of neutrality. But neutrality is a fiction in an unneutral world. There are victims, there are executioners, and there are bystanders... and the 'objectivity' of the bystander calls for inaction while other heads fall.
    Howard Zinn