Forum Replies Created

Viewing 15 posts - 2,896 through 2,910 (of 13,469 total)

  • RE: Index question

    whether the command was run with ONLINE or not is not saved anywhere, I'm pretty sure.

    peek at this scripting example, it essentially the same way i do it:

    http://www.sqlservercentral.com/scripts/Indexing/63620/

    generate the script...

  • RE: mediator between vendor and VM admin

    the size of the vendor database is one of the things i'd like to know up front;

    that's a decent initial indicator for me.

    if the entire database is say, 500 meg,...

  • RE: Find updated rows only

    abhas (11/22/2013)


    Hi All,

    I am ahving a table which contains around 150 columns and millions of rows.

    Now I am facing challenge to find among those which records are updated?

    there is no...

  • RE: Server side trace question

    RTaylor2208 (11/22/2013)


    A few questions:

    1. If you run the trace without filters for a short period of time do you see any of the events you want to capture being...

  • RE: query to return top 10 tables on each db on server

    this is much better:

    IF EXISTS (SELECT OBJECT_ID('tempdb.dbo.#tmp'))

    DROP TABLE #tmp

    CREATE TABLE [dbo].[#tmp] (

    [DBName] NVARCHAR(128) ...

  • RE: query to return top 10 tables on each db on server

    gchappell (11/21/2013)


    i need a query to return the top 10 tables in each database on a server. have used EXEC sp_msforeachtable 'sp_spaceused ''?''' which returns what I need for one...

  • RE: Maximum Number of "When Then" lines in a CASE statement?

    terrencepierce (11/21/2013)


    Hey, I appreciate the test. I have a list of thousands of entries (people have a habit of typing the same thing very different ways) that I need...

  • RE: removing lettering in front number in field

    /*

    (No column name)(No column name)Comment

    14123abcFishing lake 123abc

    19876poiElk Hunting trail 876poi

    */

    ;WITH MyCTE([Comment])

    AS

    (

    SELECT 'Fishing lake 123abc' UNION ALL

    SELECT 'Elk Hunting trail 876poi' UNION ALL

    SELECT 'Non qualifying comment'

    )

    SELECT PATINDEX('%[0-9]%',Comment),

    SUBSTRING(Comment,PATINDEX('%[0-9]%',Comment),30), --assuming only 30 chars...

  • RE: Update field based on condition

    Abu Dina (11/21/2013)

    Hi Lowell,

    Not sure this is going to work for order number A1002

    Thanks.

    you are right; after i saw your post, i realized i misread the requirement and that...

  • RE: Looping through multiple dbs in a view

    with a set list of databases, you could create a view that does multi database calls like this:

    CREATE VIEW [dbo].[VW_PERSON_DETAIL]

    AS

    SELECT

    'Database1' AS DB,

    ...

  • RE: Update field based on condition

    great job providing the DDL!

    i'm assuming the key indicator here is the OrderQty - ReceivedQty columns to determine the status.

    this seems to work for me in limited testing:

    select * ,

    orderStatus...

  • RE: I'm baffled - Msg 15022 The specified user name is already aliased

    the issue here is an orphaned user: that is, you have a SQL login [sw] , but you restored the DATABASE from another server....that local.sw <> restoreddb.sw , based on...

  • RE: odd situation

    Snargables (11/20/2013)


    How can u have the same tablename in sysobjects w/ different id's. It's making one of my processes fail. The difference in the records is the uid. I didnt...

  • RE: Database without ANY primary keys

    it might be the product of someone who thought to keep their database design as if it were secret and proprietary, and have no PK's so you can't deduce the...

  • RE: 2012 Management Studio Server Name

    briancampbellmcad (11/20/2013)


    I went to Services and found nothing relating to SQL Server.

    in that case, it sounds like you only have the SQL server Manangement Studio tools, and not a local...

Viewing 15 posts - 2,896 through 2,910 (of 13,469 total)