Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 546281
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T10:51:01+00:00 2026-05-13T10:51:01+00:00

I like to think I know enought theory, but I have little experience optimizing

  • 0

I like to think I know enought theory, but I have little experience optimizing DB in real world.
I would like to know points of view, thoughts or experiences.

Let’s imagine a scenario like:

Table A
Key: c1, c2, c3, c4
Index: c7, c3, c2

Table B
Key: c1, c2, c3, c4
Index: c1, c5

All are non-clustered.
The tables have 40+ fields.
They are feeded daily by night and have some updates during the day.

Table A, if more queries benefit from Key than Index, could the index impact negatively?
Because insert/delete has to update 2 indexes instead of 1.

Table B, has an extra field at the index, not present in key.

Could a query using c1, c5

Benefit from this Key?:
Key: c1, c2, c3, c4, c5

So that Index could be droped.

What impact does the order of the fields has?
Key: c1, c2, c3
Key: c3, c1, c2

A typical scenario for me is process_date, client_number, operation.
And it feeds with a bunch of data each day (process_date).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T10:51:02+00:00Added an answer on May 13, 2026 at 10:51 am

    if more queries benefit from Key than
    Index, could the index impact
    negatively? Because insert/delete has
    to update 2 indexes instead of 1.

    A non-clustered index has a negative impact on insert/update/delete performance. The negative impact is usually outweighed by the increased performance of selects.

    Could a query using c1, c5 Benefit
    from this Key?: Key: c1, c2, c3, c4,
    c5

    Yes, if only a few rows share the same c1, then the index will be very effective.

    What impact does the order of the
    fields has? Key: c1, c2, c3 Key: c3,
    c1, c2

    Order is important, both for filtering and ordering. An index on (c1,c2) can be used for where c1 = 1 and where c1 = 1 and c2 = 1, but not for where c2 = 1. Likewise, it helps with order by c1, but not with order by c2.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I think I have this working but I need advice. I'd like to know
i have this issue working but i would like to know if there is
I have a python question, but i think any programer would know enough to
I would like to know if ParseExact is faster than Parse. I think that
I would like to think of myself as a decent SQL Server programmer but
We have a relatively simple assignment that I understand in theory but I think
I'd like to know what you think about this part of our program is
I like vectors a lot. They're nifty and fast. But I know this thing
This may seem like a no-brainier, but the thing is I wont know the
I am using Fluent-NHibernate (with automapping) to generate my tables but would like to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.