Forum Replies Created

Viewing 15 posts - 16 through 30 (of 31 total)

  • RE: Index - Automatic Rebuild > 30 %

    Chris (6/24/2009)


    Mani Singh (6/23/2009)


    select db_name(sind.database_id) as dbname,object_name(sind.object_id,sind.database_id) as objname,sind.index_id,sind.index_type_desc,sind.avg_fragmentation_in_percent,'ALTER INDEX ON '+db_name(sind.database_id)+'.dbo.'+object_name(sind.object_id,sind.database_id)+'.'+si.name+' REBUILD WITH (FILLFACTOR = 85, SORT_IN_TEMPDB = ON STATISTICS_NORECOMPUTE = ON) ' as executethsestatemetns

    from sys.dm_db_index_physical_stats(NULL,NULL,NULL,NULL,DEFAULT) sind join sys.indexes...

  • RE: Index - Automatic Rebuild > 30 %

    Mani Singh (6/23/2009)


    select db_name(sind.database_id) as dbname,object_name(sind.object_id,sind.database_id) as objname,sind.index_id,sind.index_type_desc,sind.avg_fragmentation_in_percent,'ALTER INDEX ON '+db_name(sind.database_id)+'.dbo.'+object_name(sind.object_id,sind.database_id)+'.'+si.name+' REBUILD WITH (FILLFACTOR = 85, SORT_IN_TEMPDB = ON STATISTICS_NORECOMPUTE = ON) ' as executethsestatemetns

    from sys.dm_db_index_physical_stats(NULL,NULL,NULL,NULL,DEFAULT) sind join sys.indexes si

    on...

  • RE: Index - Automatic Rebuild > 30 %

    Mani Singh (6/23/2009)


    There are some threads about the same situation on thsi site...

    also check sp_msforeachtable and sp_msforeachdb to check for all tables in each database at one go.

    Thanks Mani Singh!

    Would...

  • RE: Multiple SQL EXECUTE's in MS Excel with VB

    --- Problem Resolved ---

    I was able to write all of my code in one MS Excel VB editor module (aka module1) instead of one sql statement for each workshet. This...

  • RE: Multiple SQL EXECUTE's in MS Excel with VB

    Ok,

    At least people are looking at this.

    Thanks for dropping by!!

    😀

    I've been thinking that I may be approaching my problem the wrong way so I created one worksheet for each...

  • RE: How to change SQL Server Collation

    My thanks to everyone for posting in this thread. Its great to see I'm not alone.

    Being the novice that I am, I'm praying that someone may have a simple...

  • RE: sql agent error - [LOG] Unable to read local eventlog (reason: The parameter is incorrect)

    Al Wells (1/18/2008)


    Running SQL Server 2005, receiving sql agent errors randomly. [LOG] Unable to read local eventlog (reason: The parameter is incorrect).

    Thank you for your help.

    I'm getting the same...

  • RE: Is it possible to rename an SQL Server name?

    Fred Siedenburg (5/17/2007)


    This worked for me;

    Run the following query in Query Analyzer to determine the name of the SQL server:

    select @@servername

    This will return the name of the server. If the...

  • RE: How to create a Windows authentication login ?

    We're so lazy! :hehe:

  • RE: How to create a Windows authentication login ?

    Hey!!!

    What if I asked my network admin to add the active directory users

    to a group and then start a 'New Login' in SQL, change the 'object

    type' from 'users' to...

  • RE: How to create a Windows authentication login ?

    Hi,

    I'm very interrested in learning how to do this as well. I'm running SQL 2005 and I have hundreds of domain\users to add and for the moment I can only...

  • RE: Only Keep The First Occurance

    RBAR,

    Thats it!

    That should do it.

    I also went to the link you mentioned and I can see how it could have helped the people in the room.

    My thanks to everyone for...

  • RE: Only Keep The First Occurance

    Chris,

    I tried to insert your statement but I'm getting errors that say:

    Msg 306, Level 16, State 2, Line 3

    The text, ntext, and image data types cannot be compared or sorted,...

  • RE: Only Keep The First Occurance

    Matt,

    Good show! I do have Crystal 9 that I'm starting to get a handle on.

    Would you have any buzzwords that could point me in the right direction?

    Thanks!!

    Chris

  • RE: Only Keep The First Occurance

    Karl,

    Thanks for your insight. I'm really new at this and a lot of the code I just posted was generated with the help of query designer.

    I don't see how...

Viewing 15 posts - 16 through 30 (of 31 total)