Forum Replies Created

Viewing 15 posts - 10,771 through 10,785 (of 14,953 total)

  • RE: using a composite column name in Select

    I guess I'm not clear on what you're asking. If you execute a select statement, you'll get a resultset on the screen.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Keyboard shortcuts whilst writing queries?

    SQL 2008 has intellisense in Management Studio. Won't work on 2005 connections, but if you write the query on a 2008 connection (Dev edition maybe), you could then port...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: A true million SSc members

    Roy Ernest (2/25/2009)


    So what kind of new idea should I come up with to get me a new T-Shirt...:D

    I'm going to suggest e-mailing Steve and asking for one. That's...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Date Function to create a monthly report (my be a dumb question)

    What do you want to change the month in? A query? A filename? The e-mail?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: How can I tell if a table has been written to?

    Yep, traces rock.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Index selection + C or NC ?

    You listed three or four different queries earlier in this thread. Try each of them on each index, see what the average run-time and IO are on all of...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Archiving data from OLTP to Archiving database

    There's a feature in SQL 2005 called "output", that can return the values from an insert. You could use that to detect which exact rows were successfully inserted into...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: How can I tell if a table has been written to?

    If you can add triggers to tables, you can log stuff that way.

    If you can get a log parser, you can check the SQL Server log files.

    If neither of those...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: using a composite column name in Select

    Check out sp_executesql. You can return values as output parameters from dynamic SQL with that.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Doubt with SQL Server Configuration Manager and SQLSAC

    When you open the surface area configuration, what server does it say it's connected to? Local?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: using a composite column name in Select

    Try replacing all of that with:

    SELECT @sql =

    'select

    dis

    from

    mshq_ivr_a1

    where

    plannbr = ' + cast(@qPlanNum as varchar(10)) + '

    and

    question = ' + cast(@qQuestion as varchar(10)) + '

    and...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Cross Apply

    Can you provide the code for the two UDFs?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: A true million SSc members

    Ninja's_RGR'us (2/24/2009)


    george sibbald (2/24/2009)


    its all yours then Gus.

    Ninja, you might want to edit that last post..................

    Since when are the words shirt and shits not interchangeable :P.

    Ok I type too fast...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Doubt with SQL Server Configuration Manager and SQLSAC

    Are you running the configuration manager on the server where you are running SQL Server, or are you running it from a separate workstation?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: using a composite column name in Select

    You'll need to use dynamic SQL to accomplish what you're talking about. Build the query string, execute it.

    For example:

    declare @sql varchar(max);

    select @sql = 'select q' + @Col + '...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

Viewing 15 posts - 10,771 through 10,785 (of 14,953 total)