Forum Replies Created

Viewing 15 posts - 12,646 through 12,660 (of 14,953 total)

  • RE: Trigger skiping the "if" condition of a cursor

    First, it is possible to modify an existing column to make it an Identity. That might solve your problem easily.

    Second, to help you with the trigger, we would need...

    - 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: Transfering data between databases

    You might want to take a look at ApexSQL Diff (www.apexsql.com), or the RedGate Compare and Data Compare products.

    I use Apex's product for migrating structure, code and data between QA...

    - 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: PRIMARY KEY constraint enforcement and tables without Clustered Indexes

    To drop those indexes, you first need to drop the PK constraint. In Management Studio, you will find those under Keys, under the table. Of course, you'll probably...

    - 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: Triger Help

    You can have the trigger test for updated rows where the ID (or other PK) is the same, but other columns (even just one) are not the same. 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: How to show the column wise data into row wise

    I always recommend doing pivot operations in a front-end application, like Excel or Reporting Services, instead of in SQL. They do it better, more easily, and faster.

    - 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: Transfering data between databases

    Is this something you will be doing once, or doing repeatedly?

    If once, the Import/Export wizard will be fine. If repeatedly, then you'll need to either save the import package...

    - 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: Help with stored procedure

    MrBaseball34 (7/24/2008)


    Would this work correctly?

    AND (((@PaymentDtTmStart IS NULL)

    AND (@PaymentDtTmEnd IS NULL))

    ...

    - 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: Dynamic Trigger creation

    You'll have to add the primary key to a Where clause in the trigger.

    - 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: Finding Start and End Dates

    (Your sample data doesn't seem to match your requirements. Take a look at the dates where the value is 6, they go 15, 17, 20, but you have a...

    - 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: Given an employee table( with columns Emp_ID,Emp_Name,Emp_Salary), how would you find out the fifth highest salary?

    Michael Earl (7/23/2008)


    When did everyone become so efficient that they started using acronyms or abbreviations for everything?

    Oh, sorry...

    WDEBSITTSUAOAFE?

    Hey, the Romans started it! It's all their fault, with their "SPQR"...

    - 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: Dumb Question

    Thanks. Was pretty sure I wasn't missing 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: Dumb Question

    I'm looking at the BOL data on DDL triggers, and I don't see Truncate Table as one of the actions. Am I overlooking 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: Dumb Question

    Steve Jones - Editor (7/23/2008)


    If you have serious auditing requirements, deleted records aren't allowed. You "mark" them as logically deleted (some flag), but you keep them around.

    Worse case, you set...

    - 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: group by causes oracle error "ORA-01403: no data found"

    Wouldn't know about a bug in the driver. I use temp tables for that kind of thing. It's not like I'm expecting SQL Server to manage transactions in...

    - 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: Getting error on maintenance plan

    I have SQL Server Agent send e-mails based on whether the job succeeded or failed. I have them go into different folders in Outlook based on the server 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

Viewing 15 posts - 12,646 through 12,660 (of 14,953 total)