Forum Replies Created

Viewing 15 posts - 4,171 through 4,185 (of 13,469 total)

  • RE: Script to show the statistics from all user tables from a DB

    nice effort!

    just as a more streamlined form, you don't need a cursor to generate the same results:

    you can do it as a single set based operation instead:

    SELECT

    object_schema_name(OBJECT_ID) as SchemaName,

    object_name(OBJECT_ID)...

  • RE: New more powerful servers are slower than old ones?

    also, because of differences in the SQL engine's optimizer between versions, if you upgrade from 2005 to 2008R2 like you said, at a minimum you need to updating statistics,...

  • RE: help me remove key lookups from the query below

    we'd need to see the actual execution plan to see if you can make it faster;

    I think what Sean Lange referred to, you want to try and convert the ...

  • RE: help me remove key lookups from the query below

    can you show us all the indexes on w_entity_document_test_new and the actual execution plan?

    did your covering index include all teh columns in the query?

    ie

    CREATE INDEX IX_tezt

    ON w_entity_document_test_new ...

  • RE: return zero for months where no data exsits

    Greg Snidow (1/4/2013)


    Lowell (1/4/2013)


    you need a Calendar table of some sort which gives you the arraay of all possible months;

    from that you change your query to select from that table,...

  • RE: UpdateStats Error 2501

    the script was originally written for SLq2000;

    it's using the old sysobjects instead of sys.tables

    now, objects are by schema, not by userr;

    so the offending code is here:

    set @tableListSQL = 'use ['...

  • RE: return zero for months where no data exsits

    you need a Calendar table of some sort which gives you the arraay of all possible months;

    from that you change your query to select from that table, and join to...

  • RE: t-sql parse out data

    wendy we need some examples, i think;

    splitting the name based on some character is easy; PARSENAME or the famous DelimitedSplit8K are two examples that come to mind;

    but unless there is...

  • RE: Can a malware on desktop affect the security of MSSQL?

    MSSQL_NOOB (1/4/2013)


    Is this security or stupidity?

    a little of both, i think.

    From a SQL server standpoint,

    SQL server passwords are inherently less secure than Windows authentication; you can use a brute...

  • RE: Track Detach in DDL Trigger?

    thinking outside the box, i think you could create a script that adds users to a role that removes backup permissions,

    on a per database level,

    ie DENY BACKUP...

  • RE: Track Detach in DDL Trigger?

    yeah DBCC commands are not DDL Events; you can do it in a trace or event notification, though;

    same thing happens when someone RESTORES a database...you cannot capture the RESTORE in...

  • RE: Track Detach in DDL Trigger?

    I just checked, and it does show up in my default trace

    here's my query i use to get to the trace data:

    /*

    --Results

    EventClassDescrip EventSubClassDescrip trace_event_id...

  • RE: Insert Into #temp table

    Roland Alexander STL (1/3/2013)


    twahl0630 (1/3/2013)


    Low hanging fruit would be to get rid of those OR's and UNION ALL a separate SELECT for each one. Also if there is any chance...

  • RE: Suppress automatic Hyperlinks in outlook in HTML format

    Mozilla Thunderbird, EditPlus and even Notepad++ as well as LOTS of other applciations all do the same thing when they encounter text that looks like an url or email, so...

  • RE: Suppress automatic Hyperlinks in outlook in HTML format

    Yeah that's a feature of Outlook, not something that has anything to do with the code you generate; it finds strings with an @ in them, and converts them to...

Viewing 15 posts - 4,171 through 4,185 (of 13,469 total)