Forum Replies Created

Viewing 15 posts - 2,836 through 2,850 (of 4,085 total)

  • RE: How to get metadata info on table? please

    asita (1/13/2016)


    I am using sql server 2008R2

    For future reference, there is a forum specifically for SQL2008. You would be better off posting in that forum, because you are less...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: How to identify duplicate data with out Primary Key

    Even though your data doesn't have a primary key, it should have one or more natural keys. You need to identify what those natural key might be and use...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: combine a datetime coulmn and varchar into new Datetime

    sqlfriends (1/12/2016)


    That is a good reminder.

    Unfortunately the original data does not have a pm, am.

    There are three possibilities:

    1) The data is set up with 24-hour times and you're all set.

    2)...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: combine a datetime coulmn and varchar into new Datetime

    Please note that since you don't include AM or PM, the hearing time will be interpreted on a 24-hour clock, so your 0330 will be 3:30 AM.

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: how count work at backend Level.

    John Mitchell-245523 (1/11/2016)


    That any integer is just a placeholder. As you've already noticed, you'll get the same result whatever argument you put in there. What you do have...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: Table Creation - Tool

    You can create the tables directly from Visio. It's been awhile, and I don't have a copy of Visio to walk you through how to do it.

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: Help need in using condition on join statement

    Hint: LIKE without wildcards in the second expression is equivalent to =

    Given that, think of it like the distributive property. You have an element in common in both inner...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: Join to pull mismatch data in tables

    You just need to slightly modify the query Lowell provided.

    SELECT * FROM #CoverageTable

    WHERE CoverageID IN ( SELECT CoverageID FROM #RateTable )

    EXCEPT

    SELECT * FROM #RateTable

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: Selecting a decimal

    Hugo Kornelis (1/6/2016)


    sql_only (1/6/2016)


    why does

    DECLARE @phi DECIMAL = (SQRT(5)+1)/2

    SELECT @phi;

    return 2

    and not 1.618

    Integer math.

    Actually, no. The SQRT function returns a decimal even though the input is an integer. ...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: Loop through an IN() clause?

    Please post sample data and expected results as specified in Forum Etiquette: How to post data/code on a forum to get the best help[/url]

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: query for datetime

    Jeff Moden (1/1/2016)


    Ostensibly, the StartDT and EndDT would be represented using the same DATETIMEOFFSET, which also does NOT change the fact that there are 24 hours in a day. ...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: query for datetime

    Jeff Moden (12/30/2015)


    Here's the code I wrote last night with the validation checks that I added today. Details are in the comments in the code.

    GREAT! But suppose your company...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: query for datetime

    Jeff Moden (12/30/2015)


    Generating data to the ms across a large range of dates is very important to testing.

    I would say that depends on what you're testing and the...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: query for datetime

    Jeff Moden (12/29/2015)


    And, no... I'm not being snarky here. I'd really like to see how others would do this using only the methods you speak of. I'll post...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

  • RE: query for datetime

    Jeff Moden (12/29/2015)


    drew.allen (12/29/2015)


    None of the newer date/time data types support decimal math.

    I consider that to be a major failure on the part of Microsoft. I'll never understand why...

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

Viewing 15 posts - 2,836 through 2,850 (of 4,085 total)