Forum Replies Created

Viewing 15 posts - 1,381 through 1,395 (of 1,923 total)

  • RE: Combining Two Tables or Question

    I am unclear of the requirement , friend! Can you please follow the instructions on this article and provide with a better question and a clear desired-result, it would be...

  • RE: How To count Number of NULLS in a row

    It all depends on your SET_ANSI_NULLS setting..

    but for starters i give u this:

    -- NULL COUNT

    SELECT COUNT(*) FROM TABLE

    WHERE COLUMN IS NULL

    -- NOT NULL COUNT

    SELECT COUNT(*) FROM TABLE

    WHERE COLUMN IS NOT...

  • RE: Cursor won't match the passed value.

    Walter, your SET statement must come before the DECLARE CURSOR

    Like:

    set @searchname = 'TTDSLS951100'

    declare mycurs cursor...

  • RE: Cross Apply in Sql

    Azzu, here are some links describing APPLY clause ; all the qustions you asked is explained in detail in the link ; i had given the link to the first...

  • RE: CTE Help - I Think I'm Close

    I guess, every recursive CTE must contain a primary anchor select, an UNION ALL and a secondary clause that will reference the name of the CTE.. recursion happens this way...

  • RE: How to list all duplicated rows which may include NULL columns?

    Hey there, try this:

    ;WITH

    duplicate (a, b,c) AS

    (

    SELECT isnull(a, '*') a , isnull(b, '*') b , count(*) c

    FROM dbo.t

    GROUP

    BY a, b

    )

    SELECT t.a, t.b

    FROM dbo.t t

    left join duplicate d

    on isnull(t.a,...

  • RE: Removing Duplicate Character from existing string

    Got a question bro, do we have to retain only the first occurence of a duplicated character in that string?

  • RE: HOW To write this query?

    ColdCoffee (6/8/2010)


    and post data in readily consumable format, so that every one will give it a shot..

    see as i was saying this, and as there was sample data in readily...

  • RE: HOW To write this query?

    Jan Van der Eecken (6/8/2010)


    Why make it that complicated?

    SELECT FatherId, MAX ( age ) AS 'age'

    FROM @Fathers

    GROUP BY FatherId

    Or am I missing something?

    Jan Van , think u probably missed...

  • RE: HOW To write this query?

    As this is fairly simple to construct, i myself created the sample data and scripts and the code.. in future, u can follow what Jan Van said and post data...

  • RE: HOW To write this query?

    Hey there, try this :

    DECLARE @Fathers TABLE (FatherId VARCHAR(10), age INT)

    INSERT INTO @Fathers

    SELECT 'Father1', 12

    UNION ALL SELECT 'Father1', 17

    UNION...

  • RE: Records between 2 Dates

    I really cant understand your request, Lucky! Please provide us sample data, sample tables and a clear-desired result.. Please read thro this article on how to post data so that...

  • RE: Records between 2 Dates

    Hey there, Whats the relation between ABC and XYZ ?

  • RE: DDL Trigger to monitor server changes

    My cent is on the SQL Server Profiler.. THis will clearly let you know the exaclt T-SQL statement being run.. I am not big-shot in Profiler, so probably our other...

  • RE: Return txt from string

    skcadavre (6/7/2010)


    ColdCoffee (6/7/2010)


    skcadavre (6/7/2010)


    ColdCoffee (6/7/2010)


    If your request is what Sckadavre is saying, then this might help you! This code doesn use a self-referencing CTE, but assuming your string contains only...

Viewing 15 posts - 1,381 through 1,395 (of 1,923 total)