Forum Replies Created

Viewing 15 posts - 1 through 15 (of 122 total)

  • RE: Why does SQL chooses Index Scans over Index Seeks

    See if the PK is a clustered index as well...... if so it's logical it will fall back to an index scan...

     

  • RE: Dynamic Audit Trigger

    Maybe a little late but I contributed a script wich will audit any table.....

    It looks if a specificv audit table is present, if it isn't it will create a...

  • RE: Looking for Visual Basic .Net demo code using SQL client .net provider

    Dim MyConn As SqlConnection = "YOUR SQL CONNECTION"

    Dim mySqlCommand As SqlCommand = New SqlCommand("ListPublication", MyConn)

                If MyConn.State <> ConnectionState.Open Then

                    MyConn.Open()

                End If

                mySqlCommand.CommandType = CommandType.StoredProcedure

                SqlCommandBuilder.DeriveParameters(mySqlCommand)

                mySqlCommand.Parameters(1).Value = PublicationID

                Dim...

  • RE: Transactional Replication

    Several possibillities.....

    1. There are multiple instances running on the computer.

    2. Disable all unneccesary protocols in SQL Server. (ONLY TCP/IP) and no namede pipes

    3. Delete everey protocol in windows. Only TCP...

  • RE: Script to see if SQLAgent is running

    Thanks but this is not what i am looking for.

    It would be a diagnostic query.

    And installing all kind of stuff on a production server is out of the question.....

    Any other...

  • RE: Indexes

    Don't know if this is the case but in a live situatiuon you can encounter a long lasting lock and this can affect queries....

    To get rid of the lock try...

  • RE: pages clustered/non-clustered index

    Also it is important how many data you need from the row...

    If you need only the fields mentioned in the query you could use covering indexes....

    If the rows are very...

  • RE: Index for column with a lot of Null

    I am not trying to offend anyone but if for a certein column the null percentage is 65% or higher i suggest moving those fields out of the table.

    Why whase...

  • RE: Looping Through Records

    I had a second thought....

    If you are really working with millions of rows.... Is iterating through every record the best way then.

    My guess is that a set based operation will...

  • RE: Insert SQL statement into a table

    i mean what if the user uses SP_EXECUTESQL in his query ??????

  • RE: Looping Through Records

    I agree with Guarddata...

    Ther is now way of us knowing in advance what will be the optimum solution.

    So there is nothing left to do then build a small prototype of...

  • RE: Query Performance

    The queru on the permanent table has to do less actions.

    Doesn't need to allocate memory, free up memory etc.

    A good point made before is the size of the memory table....

  • RE: Looping Through Records

    Create a memory table with an identity column and the pk of the table.

    below a small example :

    declare @counter as integer

    declare @maxcount as integer -- Used for upper bounds

    declare @keyval...

  • RE: Insert SQL statement into a table

    If any SQL statement would be valid....

    Would an Exec or sp_executesql be valid as well.......

  • RE: Insert SQL statement into a table

    Well this is maybe a very stupid reply but maybe it isn't......

    1. Pass the sql-query to a stored procedure as a parameter, the quotes issue should be solved then.

    2. Dont...

Viewing 15 posts - 1 through 15 (of 122 total)