Forum Replies Created

Viewing 15 posts - 14,341 through 14,355 (of 14,953 total)

  • RE: Excel's Trunc function?what about sql 2005?

    You're welcome. (And thank you for the compliment.)

    - 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: need to get columns dynamically n compare two tables

    I guess I'd have to see the database to figure out what you've got. I'm not following you on this. I don't think I'll be able to help....

    - 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: Excel's Trunc function?what about sql 2005?

    And for the other part of your question, if you want numbers that have more than 2 decimal places:

    where number * 100 > floor(number * 100)

    Use Floor in this case,...

    - 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: Excel's Trunc function?what about sql 2005?

    Cast(number as int) will do what you need.

    Examples:

    cast(8.7 as int) = 8

    cast(-8.7 as int) = -8

    cast(pi() as int) = 3

    Convert will do the same, but has reversed syntax:

    convert(int, 8.7)

    convert(int,...

    - 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: need to get columns dynamically n compare two tables

    I don't know what you mean by "after every iteration table changes".

    - 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: What kind of DBA are you?

    I pronounce it the same as I would for a really bad movie that comes out after a really good one.

    My boss keeps talking about one day brushing up on...

    - 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: Installing SS2005 on laptop with Vista

    I've run SQL 2005 Express and Dev Edition on both Vista Home Premium and Vista Ultimate.

    The main thing to watch out for is, when installing, uncheck the boxes at the...

    - 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: Divide by Zero

    Okay. If you're in a position to do so, you might just want to double-check that point with the people who are going to be using it.

    - 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: SQL server versus SQL server express

    If I understand correctly, you are currently using SQL Server Express for the database. If that's correct, an upgrade very well might improve your applications speed a bit.

    SQL Express...

    - 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: need to get columns dynamically n compare two tables

    I got completely lost when I tried to read this.

    Are you saying that you have two tables, that they have the same columns as each other, but that the data...

    - 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: Divide by Zero

    I just took another look at your code, and, regardless of the effect of zeroes on it, are you sure you want to divide two different directions in the same...

    - 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: Divide by Zero

    Move the tests for 0 first in the Case statement. That should get it.

    - 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: write to XML file

    I've had trouble using BCP with procs, if I remember correctly. May not work that way.

    Books Online has an article on importing/exporting XML at ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/dff99404-a002-48ee-910e-f37f013d946d.htm

    Check that out and it...

    - 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: What shall I do with large tables with most of rows expired?

    It looks like your main index on your Subscriptions table should be:

    create index IDX_Subscriptions_Main

    on dbo.Subscriptions (UserName, ChannelUniqueID, SubscriptionEnd, SubscriptionApproved,

    FeePaid)

    That will cover what you need for that query. You...

    - 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: Re-Create File from column in table.

    I haven't tried it, but I believe openrowset can write to files as well as read from them. You might try 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

Viewing 15 posts - 14,341 through 14,355 (of 14,953 total)