Forum Replies Created

Viewing 15 posts - 796 through 810 (of 3,348 total)

  • RE: Nested View and NoLock

    DB_Newbie2007 (2/18/2016)


    (...)

    3. We now have a customer that wishes

    (...)

    which the customer does not wish to pay for.

    At this point, I would tell the customer to make up their mind....

  • RE: Calculation without Cursor suggestions

    Thanks for posting back. I am glad that this works for you!

  • RE: How to query a Denormalised table

    Your basic problem is not in the queries, but in the table. Look at the data and then at the data types you used for the columns. Choosing inappropriate data...

  • RE: TRY_CONVERT smaller

    Ouch. Burned.

    Thanks, Carlo! I really should have known that.

  • RE: Sub query where clause returns nothing

    Sergiy (2/17/2016)


    Jacob Wilkins (2/17/2016)


    Sergiy (2/17/2016)


    Since you're not returning anything from table t2 there is no point in using a JOIN.

    Check for existence would do just fine:

    select t1.[StockCode],t1.[SalesOrder],t1.[SalesOrderLine],t1.[LotNumber],t1.[Customer],

    t2.[ShipDate][/i],

    from table t1

    WHERE...

  • RE: TRY_CONVERT smaller

    Carlo Romagnano (2/18/2016)


    That's easy!

    But, try to answer this:

    "What's the resut?"

    SELECT TRY_CONVERT(VARCHAR(1), {D'2011-MAY-01'})

    :-D:-D:-D

    The correct answer to this question is "it depends".

    Now my question to you is if you can figure out...

  • RE: TRY_CONVERT smaller

    I *almost* gave the answer that would have been correct for SELECT TRY_CONVERT(VARCHAR(1), 234523). Almost.

    Also, I would like to know how many people would have selected NULL if that had...

  • RE: Identity field for batch migrating data

    This looks like mostly a repeat of your earlier question, so the same answers apply. Short version: it deppends on what exactly the functional requjirements are. Find them, and the...

  • RE: Loading xml data into SQL server 2012 table

    Something like this?

    DECLARE @x xml = '<Validations>

    <ActivityID>17626</ActivityID>

    <validation id="ActivityIdPass" status="Fail">An Activity ID must be defined.</validation>

    <validation id="ActivityFormatPass" status="Pass">Passed</validation>

    <validation id="ActivityFormatSubCatPass" status="Pass">Passed</validation>

    <validation id="StartDateTimePass" status="Fail">A Release Date must be defined</validation>

    <validation id="EndDateTimePass" status="Fail">An Expiration Date must...

  • RE: Sub query where clause returns nothing

    spin (2/17/2016)


    Thanks for the replies..

    perhaps i should have given my final expectations...

    i have 2 tables which i'm trying to join. I know the lot exists under the conditions in the...

  • RE: Bulkinsert error

    adonetok (2/17/2016)


    I used code below to insert txt file to a table from local drive but got an error said

    Cannot bulk load because the file "d:\order.TXT" could not be...

  • RE: Retrieving data per time interval help

    Since you have the "value" column in the group by clause, you will get a separate row returned for every value that is measured in each one-,minute interval.

    For more extensive...

  • RE: Select From XML Feild

    It would have been a lot easier if you had posted the full question immediately.

    Below is the code to get both the node name and the "vid" attribute value for...

  • RE: Want to Calculate Business Working hours

    mona_vahab (2/16/2016)


    Hello,

    I have the same question but the problem is in my case the login and logout time is not indicated. Could you please kindly help me with that.

    There are...

  • RE: Replace Cursor with alternative solution

    PritamSalvi (2/16/2016)


    I want to replace cursors in the queries.

    Please provide me the code in which cursor is not used.

    Thanks for the help.

    I believe that Alan did just that. Not a...

Viewing 15 posts - 796 through 810 (of 3,348 total)