You are not logged in. Your edit will be placed in a queue until it is peer reviewed.
We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.
Required fields*
-
Thank you for the very detailed reply. @Hogan below also mentioned indexing, but this is not a concept I'm familiar with. "Indexable" is set to "Yes" for each field in the database, but I don't know if that is the same thing you are talking about. I do have an ID column that is otherwise unused. Current Table Layout: i.imgur.com/c4sNaUy.jpg. What is the optimal method (do you have a link) to enable this clustered index?Beems– Beems2015-12-19 15:48:35 +00:00Commented Dec 19, 2015 at 15:48
-
Indexable to yes is definitely not the same thing. I'd make sure the clustered index (primary key) on the table uses the f_starttime, f_computername, f_application, f_endtime, f_ID fields, similar to what I suggested in the answer, and make sure to put the columns in the index in that order.Joel Coehoorn– Joel Coehoorn2015-12-19 17:24:40 +00:00Commented Dec 19, 2015 at 17:24
-
Thank you for the help thus far. I've been reading as much as I can regarding your suggestions. I have the columns in the index as you stated, so my last questions are: Should the "Is Unique" option be set as "Yes" and should the "Create as Clustered" option be set to "Yes" as well? Screenshot of settings: imgur.com/uQ3fF31.jpgBeems– Beems2016-01-04 22:11:44 +00:00Commented Jan 4, 2016 at 22:11
-
You do want "Is Clustered" to be "yes" here. "Is Unique" should be yes only if you can guarantee those columns will always refer to a specific record. If it's even remotely possible for two instances of the same app on the same computer to report the same start time, you'll either need a way to tell the records apart or you'll need to set "Is Unique" to "No". Typically, you do want your clustered indexes to be unique; you want to set this to "Yes" if you can. However, it's not required, and collisions in this case should be rare enough to avoid problems if you are unable to guarantee itJoel Coehoorn– Joel Coehoorn2016-01-04 22:16:26 +00:00Commented Jan 4, 2016 at 22:16
-
2If this helped, I'd really like to hear some before and after numbers.Joel Coehoorn– Joel Coehoorn2016-01-05 19:06:02 +00:00Commented Jan 5, 2016 at 19:06
|
Show 2 more comments
How to Edit
- Correct minor typos or mistakes
- Clarify meaning without changing it
- Add related resources or links
- Always respect the author’s intent
- Don’t use edits to reply to the author
How to Format
-
create code fences with backticks ` or tildes ~
```
like so
``` -
add language identifier to highlight code
```python
def function(foo):
print(foo)
``` - put returns between paragraphs
- for linebreak add 2 spaces at end
- _italic_ or **bold**
- indent code by 4 spaces
- backtick escapes
`like _so_` - quote by placing > at start of line
- to make links (use https whenever possible)
<https://example.com>[example](https://example.com)<a href="https://example.com">example</a>
How to Tag
A tag is a keyword or label that categorizes your question with other, similar questions. Choose one or more (up to 5) tags that will help answerers to find and interpret your question.
- complete the sentence: my question is about...
- use tags that describe things or concepts that are essential, not incidental to your question
- favor using existing popular tags
- read the descriptions that appear below the tag
If your question is primarily about a topic for which you can't find a tag:
- combine multiple words into single-words with hyphens (e.g. sql-server), up to a maximum of 35 characters
- creating new tags is a privilege; if you can't yet create a tag you need, then post this question without it, then ask the community to create it for you
lang-sql