Forum Replies Created

Viewing 15 posts - 721 through 735 (of 859 total)

  • RE: Most Efficient Way to Transfer ERD to SQL server

    flebber.crue (4/2/2012)


    I never thought about keeping the scripts for backup but that is a good point.

    Is there a good editor to write the SQL in?

    i find i like...

  • RE: Kinda fancy reports with multiple counts and multiple group by

    i count 3 distinct queries with changes on the where clauses and SSRS to make it all nice and pretty.

    one for the partner level (changing the date range for...

  • RE: sql parameters

    roryp 96873 (4/2/2012)


    capn.hector (4/2/2012)


    roryp 96873 (4/2/2012)


    capn.hector (4/2/2012)


    roryp 96873 (4/2/2012)


    Something like this?

    declare @myDate date

    set @myDate = '2012-04-02'

    select @myDate as myDate

    Obviously this is really simple, but you can use the @myDate in...

  • RE: sql parameters

    roryp 96873 (4/2/2012)


    capn.hector (4/2/2012)


    roryp 96873 (4/2/2012)


    Something like this?

    declare @myDate date

    set @myDate = '2012-04-02'

    select @myDate as myDate

    Obviously this is really simple, but you can use the @myDate in calculations or comparisions...

  • RE: Kinda fancy reports with multiple counts and multiple group by

    using common table expressions you can get the aggergated data but with out the DDL and sample data code is hard to do. there are also cross tabs that...

  • RE: sql parameters

    roryp 96873 (4/2/2012)


    Something like this?

    declare @myDate date

    set @myDate = '2012-04-02'

    select @myDate as myDate

    Obviously this is really simple, but you can use the @myDate in calculations or comparisions like you would...

  • RE: how to delete all except results of select statement

    aaron.reese (4/2/2012)


    yes, that is probably a better syntax (personally I think it is a little harder to read) but it will work for multi-part primary keys whereas the IN (SELECT...)...

  • RE: Are the posted questions getting worse?

    SQLRNNR (4/2/2012)


    jcrawf02 (4/2/2012)


    Brandie Tarvin (3/29/2012)


    Greg Edwards-268690 (3/29/2012)


    Brandie Tarvin (3/29/2012)


    Just spent time in a meeting being reminded that people using the same terms do not always mean the same thing. Interesting...

  • RE: SQL Bits X...

    Sean Lange (4/2/2012)


    Koen Verbeeck (4/2/2012)


    Sean Lange (3/30/2012)


    I made him read this whole thread. http://www.sqlservercentral.com/Forums/Topic1268991-391-1.aspx :w00t:

    Hi-la-rious!

    I do admire your patience.

    I would probably already stopped looking at that thread after 3 or...

  • RE: Update on large table using SELECT

    Sean Lange (4/2/2012)


    It really looks like this should be a single update instead of rbar.

    i agree. of course this could also be inside of a cursor all ready (Similar...

  • RE: Refactoring an SP - stuck on a query

    SQLKnowItAll (4/2/2012)


    capn.hector (4/2/2012)


    i was wrong, here it is with the join and only pulling authid's in the trans table

    ;WITH row AS (SELECT ROW_NUMBER() OVER (Partition by auth_id ORDER BY key_id)...

  • RE: Refactoring an SP - stuck on a query

    i was wrong, here it is with the join and only pulling authid's in the trans table

    ;WITH row AS (SELECT ROW_NUMBER() OVER (Partition by auth_id ORDER BY key_id) AS rownum,...

  • RE: Refactoring an SP - stuck on a query

    ;WITH row AS (SELECT ROW_NUMBER() OVER (Partition by auth_id ORDER BY key_id) AS rownum, cpt4_id, auth_id FROM #outpatient_service)

    SELECT UPPER(cpt4_id), auth_id FROM row where rownum = 1

    GO

    no inner join to the...

  • RE: Most Efficient Way to Transfer ERD to SQL server

    i find scripting the database out is better for me than using any tool to do it for me from visio (or the such) from an ERD. the first...

  • RE: Refactoring an SP - stuck on a query

    Pam Brisjar (4/2/2012)


    Goal: change "WHERE auth_id = @auth_id" to an inner join with the #TRANS table and get rid of that subquery.

    Help?

    question where in the query is the...

Viewing 15 posts - 721 through 735 (of 859 total)