Forum Replies Created

Viewing 15 posts - 6,046 through 6,060 (of 8,731 total)

  • RE: Possible sub select dilemma

    I'm not sure if this is what you're looking for.

    DECLARE @Table1 TABLE(

    Id char(1))

    INSERT @Table1 VALUES('A'), ('B')

    DECLARE @Table2 TABLE(

    Id char(1),

    ...

  • RE: SSRS - Formatting a multi-value field??

    Something like this?

    SELECT STUFF(( SELECT ', ' + '$' + STUFF( svalue, LEN( svalue) - 1, 0, '.') FROM (VALUES('1299'),('397'),('1500'),('11001'))x(svalue)

    FOR

    XML PATH('')

    ), 1, 2, ' ')

  • RE: compatibility vs native mssql2000 to 2008

    mjuarezh36 (7/30/2014)


    Hello.

    Actually we have an Enterprise based applications with MS-SQL2000 , we have microsoft Dinamycs (6.5) and several applications (vb.net 2005, 2010 y 2012), .

    But now we plan to migrate...

  • RE: SSRS - Formatting a multi-value field??

    If you're receiving the values as a comma-separated list, then you should format them in the back-end. In other words, you need to format the values before the concatenation.

  • RE: SQL query

    The common way is to use ROW_NUMBER() within a CTE or subquery.

    WITH CTE AS(

    SELECT a.id,

    a.first_name,

    ...

  • RE: Today's Humor..

    Eirikur Eiriksson (7/30/2014)


    Luis Cazares (7/30/2014)


    Alvin Ramard (7/30/2014)


    WAIT!!!! What kind of database MUST be repaired regularly???? :w00t:

    The one that is shrinked regularly?

    Guess shrinked is the simple mode and shrunken...

  • RE: Today's Humor..

    Alvin Ramard (7/30/2014)


    WAIT!!!! What kind of database MUST be repaired regularly???? :w00t:

    The one that is shrinked regularly?

  • RE: Today's Humor..

    Don't forget to use NOLOCK hints on all your queries and never ever run DBCC CHECKD, update statistics or rebuild indexes. You might encounter a lot of objects locked during...

  • RE: I'm totally new. Need some guide on SQL 2012

    You're missing the last 2 columns in your insert statement. You need to modify it to include those values.

  • RE: table variable declaration inside a loop

    Xavon (7/30/2014)


    patrickmcginnis59 10839 (7/30/2014)


    Xavon (7/30/2014)


    But you still can't use a variable before you declare it...

    This 'logic' makes my head hurt.

    When that error is picked up, its actually checking to see...

  • RE: ssis Training

    This might help:

    Stairway to Integration Services[/url]

  • RE: I'm totally new. Need some guide on SQL 2012

    And that's why it is considered best practice to include the column list of the destination table. Something like the following, but I don't know how the real structure of...

  • RE: Multiple joins to the same table

    Try searching sargable.

  • RE: Conversion from varchar to strong data types

    Why don't you use some TRY...CATCH... blocks?

    Here's an example:

    DECLARE @i int, @Error varchar(100) = ''

    BEGIN TRY

    SET @i = 'a'

    END TRY

    BEGIN CATCH

    SET @Error...

  • RE: Multiple joins to the same table

    I often think of APPLY as a JOIN on steroids. 😀

    Apply will allow you to use correlated subqueries as tables/views or columns from other tables as parameters of functions. I...

Viewing 15 posts - 6,046 through 6,060 (of 8,731 total)