Forum Replies Created

Viewing 15 posts - 20,701 through 20,715 (of 22,196 total)

  • RE: What kind of DBA are you?

    Well, let's push it along a bit.

    SEQUEL Server 2008 is nifty!

  • RE: How to get HIT RATIO

    Looks like the post has smileys in place of parenthesis, but yeah, the query is working fine once those are replaced.

  • RE: Best Way to write an Update Stored Procedure

    I don't have supporting documentation and lists of tests at hand, but we generally either call for all parameters to be passed and then update all the columns every time...

  • RE: Binary As Primary/Foreign Key?

    Uh-oh. Heads up! Celko incoming!

    😉

    But seriously, that's getting into the natural vs. artifial key argument. If the he is following the natural key approach and the smallint field (bitmapped, honestly,...

  • RE: Troubleshooting Query

    That means a default clustered index has been created on the primary key of the table. From your description, I assume on the column CountyId.

    However, if you only have a...

  • RE: How to get HIT RATIO

    I took that straight from the link provided. My bad for not checking it. Here's a quick & dirty version that works correctly

    SELECT (a.cntr_value * 1.0 / b.cntr_value) * 100.0...

  • RE: How to get HIT RATIO

    Here's one way to use the data:

    SELECT (a.cntr_value * 1.0 / b.cntr_value) * 100.0 [BufferCacheHitRatio]

    FROM (SELECT *, 1 x FROM sys.dm_os_performance_counters

    ...

  • RE: How to get HIT RATIO

    You can get some from queries. For example, the dynamic management view sys.dm_os_performance_counters contains the buffer cache hit ratio.

  • RE: Conditional insert

    Sorry, I stated that badly. I'm not aware of any exceptions.

    The one thing that might be an exception would be that the SELECT statement can only return the same number...

  • RE: Binary As Primary/Foreign Key?

    Well, my initial response would be, no, poor choice. On further reflection, I'll fall back on the usual answer, it depends.

    Are you using natural keys in your table design...

  • RE: ALTER TABLE ALTER COLUMN (PRIMARY KEY)

    Nah, they were just working on their server and typed into the wrong window. I do the same thing all the time. In fact, that explains most of my posts.

    :w00t:

  • RE: Troubleshooting Query

    You have 9000 rows for the county of Austin and you're filtering by the county of Austin... You're going to get a table scan or index scan no matter what...

  • RE: SQL Function not returning any value

    Much more than compilation. Functions come in two basic flavors, table valued & scalar valued. Scalar is used for a calculation, table valued are sort of like parameterized views. Only...

  • RE: What shall I do with large tables with most of rows expired?

    No way, you're not wrong. It's just a question of trade-offs. Does having the "dead" rows affect general performance of the system? No? Then you have to weigh whether or...

  • RE: Conditional insert

    Mahesh beat me to it.

    Once you realize that the INSERT...SELECT mechanism is just a SELECT statement, pretty much anything possible within the SELECT statement can be used with the INSERT...

Viewing 15 posts - 20,701 through 20,715 (of 22,196 total)