Forum Replies Created

Viewing 15 posts - 6,556 through 6,570 (of 7,413 total)

  • RE: Rows being dropped in query

    is there something in the join that could be counting these records out?

    Maybe in some cases "s.[to Date of service]" is NULL to indicate "no end date"?

  • RE: What, if any, is the best type of replication for implementing on hundreds of databases on one server?

    You need to do mirroring at the disk level, not the database level. The number of databases is then irrelevent, it's only the total volume of changes that is...

  • RE: Summerizing 1 field from 6 selected.

    If you can accept the total stand-alone in a different result set, you can add this:

    COMPUTE SUM(acres) --but will NOT work in SQL 2012!

    to your query.

  • RE: TempDB questions

    Alexander Suprun (2/21/2013)


    ScottPletcher (2/21/2013)


    RAM is always used first to hold temp tables and table variables. But, if (and only if) RAM available for holding such rows is exceeded, then...

  • RE: Filtered Indexes - Simple Partitioning without Enterprise Edition?

    Did you try just putting the Status column only in the index? SQL can still use that index to do a key lookup back to the main table. ...

  • RE: TSQL Optimization - CASTing and CURSOR

    Is CASTing cost an additional overhead to the query?

    In this case, no. In fact, here it might actually help ever so slightly.

    SQL has to determine a datatype for...

  • RE: Index question

    Are Transaction_Numbers -- i.e. clustered key values -- added in ascending sequence?

    If so, make sure SQL is sorting the rows before doing the INSERTs.

    If not, and you're sure you have...

  • RE: TempDB questions

    bangsql (2/21/2013)


    1. any query uses group by , order by etc.. uses tempdb.

    so if view contains that tempdb will use

    2. no of physical cpu = no of tempdb files.

    RAM...

  • RE: TempDB questions

    1) I know temporary tables and table variables occupy space in TempDB, but what happens when I invoke a view; do views also make demands on TempDB?

    2) What is the...

  • RE: Issue With Update trigger on storeprocedure

    I support the idea of using CONTEXT_INFO for this.

    But I'd suggest limiting the use of it to a single, predefined byte location. And also not destroying any unused in...

  • RE: Instead of Insert and Insert Trigger

    The "instead of" trigger will fire first.

    If the "instead of" trigger does actually insert a row(s), then the "after[for] trigger" will fire.

    You may want to use the clearer "AFTER INSERT"...

  • RE: Display on Month and Year from date formula ??

    Jeff Moden (2/19/2013)


    ScottPletcher (2/18/2013)


    Jeff Moden (2/18/2013)


    ScottPletcher (2/18/2013)


    declare @enddate datetime

    set @enddate = getdate()

    SELECT STUFF(CONVERT(varchar(10), DATEADD(DAY, -21, @enddate), 1), 3, 4, '')

    Except for Sean, we did forget to answer the original question....

  • RE: DWH : Fact table : index creation.

    Jason-299789 (2/19/2013)


    Scott,

    I would disagree with you on the under no circumstances comment, for a couple of reasons

    1) the risk of fragmentation is significant on the clustered index, especially if...

  • RE: DWH : Fact table : index creation.

    Bhuvnesh (2/18/2013)


    ScottPletcher (2/18/2013)


    Under no circumstances should you cluster this table on Policy_transactional_ID.

    Cluster the table by the most common WHERE conditions; make the clustered key unique by including the Policy_transactional_ID on...

  • RE: Problem Capturing Constraint Violations Using INSTEAD OF Trigger

    David Moutray (2/18/2013)


    ScottPletcher (2/18/2013)


    All triggers are implicitly part of a transaction, with at least the SQL statement that caused the trigger to fire included in the transaction.

    In implicit transaction mode,...

Viewing 15 posts - 6,556 through 6,570 (of 7,413 total)