Forum Replies Created

Viewing 15 posts - 8,131 through 8,145 (of 26,490 total)

  • RE: Dynamic SQL: IN/JOIN

    5280_Lifestyle (4/5/2013)


    Full query...

    DECLARE @c varchar(4000)

    SET @c = '

    SELECT DISTINCT AL1.user_id_entered, AL1.reservation_id, AL1.start_date, AL1.status_code, AL1.actual_minutes, AL1.scheduled_minutes,

    AL1.customer_abbr, AL2.company_name, AL2.parent_company, AL1.reservation_name, AL1.product, AL1.customer_extend, AL1.category_abbr,

    AL1.reason_code, CONVERT(varchar(3),AL1.start_date,100) AS StartDateMonth, YEAR(AL1.start_date) AS StartDateYear,

    CASE

    WHEN MONTH(AL1.start_date)...

  • RE: How to get result sets when using dynamic query

    hafsahafeez91 (4/5/2013)


    hey Lynn! i attached two images one image is displaying the sample data and the other is the output m getting ! I need the output as

    ...

  • RE: ?? on set parameter to today if date in future?

    jbalbo (4/5/2013)


    Hi

    Does anyone know how I can setup this where statement to

    have @enddate be now() if the date is in the future?

    (calendarDate BETWEEN @startdate AND @enddate)

    Thanks

    Joe

    Curious how hard you...

  • RE: Dynamic SQL: IN/JOIN

    5280_Lifestyle (4/5/2013)


    I'm trying to get two drop-down multi-valued parameters working in my report. If I hard-code my values into my query, then the report runs as it should. When I...

  • RE: How to get result sets when using dynamic query

    Nope, can't provide more help as I have nothing to work with here. You will need to post the DDL for your tables, sample data, and expected results. ...

  • RE: Possible bug in Microsoft system stored procedure

    David McKinney (4/5/2013)


    We didn't declare a smallint, Bill Gates and his pals did.

    First, I would not blame Bill Gates for this.

    Looking at the code for sys.sp_fulltext_catalog I can definately see...

  • RE: How to get result sets when using dynamic query

    Probably something along these lines:

    CREATE PROCEDURE [dbo].[Get_Ques_id_for_can](

    @candidate_id varchar(max),

    @Exam_id varchar(max),

    @sec_id bigint,

    @Q_id varchar(max) OUTPUT

    )

    AS

    ...

  • RE: How to preserve global temporary table data

    And, if you think about it, it comes down to how is the requirement is specified. The two following requirements are different:

    The system must (or shall) retain the original...

  • RE: How to preserve global temporary table data

    ScottPletcher (4/4/2013)


    Lynn Pettis (4/4/2013)


    Not saying I am right or wrong. I wanted a straight answer to a straight question: Is it a problem to lose the data if there...

  • RE: Odd behaviour from sys.dependencies

    JJB@TGT (4/4/2013)


    Ok, done some investigation on column collation. I've cross referenced sys.columns on the object_id and column_id like so:

    SELECT DISTINCT

    Ref.referenced_database_name AS ImportDatabase

    ,Ref.referenced_schema_name...

  • RE: How to preserve global temporary table data

    Not saying I am right or wrong. I wanted a straight answer to a straight question: Is it a problem to lose the data if there is an restart...

  • RE: How to preserve global temporary table data

    ScottPletcher (4/4/2013)


    Lynn Pettis (4/4/2013)


    ScottPletcher (4/4/2013)


    You're vastly more likely to lose a single connection than have the entire instance go down, which would kill a temp table from that connection as...

  • RE: How to preserve global temporary table data

    ScottPletcher (4/4/2013)


    You're vastly more likely to lose a single connection than have the entire instance go down, which would kill a temp table from that connection as well.

    I mean, seriously,...

  • RE: How to preserve global temporary table data

    Lowell (4/4/2013)


    rajarshi_ghosh_05 (4/4/2013)


    {snip}

    No. We dont bother about the temp table data not if anything happens like network failure or server restart or user system restart! We dont have to preserve...

  • RE: Date functions..

    Actually, lookup FORMAT in BOL for SQL Server 2012.

Viewing 15 posts - 8,131 through 8,145 (of 26,490 total)