Forum Replies Created

Viewing 15 posts - 16 through 30 (of 204 total)

  • RE: SQL Code QA

    drew.allen (9/8/2016)


    Also, my approach can easily be used with derived tables, again being consistent. You're approach could quickly become cumbersome with derived tables.

    Drew

    How?

  • RE: SQL Code QA

    Phil Parkin (9/8/2016)


    In my opinion, Drew's approach is more consistent than putting short ON clauses on one line and longer ON clauses on two (because 'longer' is a qualitative measure,...

  • RE: SQL Code QA

    Phil Parkin (9/8/2016)


    I disagree. It makes perfect sense. He *always puts ON clauses on separate indented lines* – perfectly consistent.

    That's the point I'm making - it's consistent, but no more...

  • RE: SQL Code QA

    drew.allen (9/7/2016)


    I always put my ON clauses on a separate indented line, because I want to keep it consistent. I treat short and long JOIN clauses the same, if...

  • RE: autosave (not autorecover)

    Brilliant - that's the one, thanks 🙂

  • RE: Lessons from Little Green Army Men

    djackson 22568 (2/19/2016)


    ... Our society has a huge issue with thinking that we have a right to not be offended. The way to handle that is the delete button.

    OMG,...

  • RE: Lessons from Little Green Army Men

    I don't think we'll get very far by trying to demonstrate things "how they should be", particularly if we could be following accepted behaviour ourselves.

    Rather, I feel it's better...

  • RE: Lessons from Little Green Army Men

    richlion2 (2/19/2016)


    Yet another blog type article, why do people feel compelled to tell every possible story they have to tell? No toy women soldiers? So what? It's one of those...

  • RE: Lessons from Little Green Army Men

    Just do what you're doing Andy, you're doing a great job.

  • RE: Positive or Negative

    Eric M Russell (10/23/2015)


    To determine active / inactive status, I'm not looking for a specific value; it's

    contextual based on a range comparison.

    -- return all currently active customers:

    select * from...

  • RE: Positive or Negative

    angel-626714 (10/23/2015)


    david.wright-948385 (10/23/2015)


    You have two indicators for the same thing: the flag, and whether the date is null. So it's possible to have a non-null cancellation date with a flag...

  • RE: Positive or Negative

    RonKyle (10/23/2015)


    That's perfectly fine. It relates to the individual record. Where's the denormalization in that?

    You have two indicators for the same thing: the flag, and whether the date...

  • RE: Positive or Negative

    Eric M Russell (10/23/2015)


    I've found a Date type is more useful for indicating active / inactive status. I want to know when, not just if, a row changed to inactive...

  • RE: Positive or Negative

    angel-626714 (10/23/2015)


    I would also have a column for the date and time it became inactive.

    Denormalisation alert 🙂

  • RE: Positive or Negative

    Henk Schreij (10/23/2015)


    Not exactly an answer to the question, but I use a field named State, Status, or Condition.

    VARCHAR(1), Default '' (an empty string).

    I fill this field with a Char...

Viewing 15 posts - 16 through 30 (of 204 total)