Forum Replies Created

Viewing 15 posts - 4,486 through 4,500 (of 8,731 total)

  • RE: Loop through date time records to find a match from multiple other date time records

    It's preferred to use IF EXISTS instead of COUNT(*) to prevent unnecessary reads. EXISTS will stop on the first occurrence, while COUNT(*) will read all the needed rows.

    IF EXISTS(SELECT MO.ProposedEvent

    FROM...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Interview Questions Help

    I would try to go from the basics to the more advanced things to help to determine easier the knowledge and also to give an easy start for the candidates...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Best design for OLTP tables

    Uwe Ricken (8/6/2015)


    Hallo Wayne,

    your measures are not correct because you didn't run the process:

    - for each table separately

    - with 200 concurrent Connections

    Than you will have a HIGH fragmentation on the...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Dynamic query Pivot values change

    I just thought on giving a shorter solution that uses a tally table.

    CREATE TABLE dbo.TestPivot(

    CollectionDate DATETIME,

    Products VARCHAR(40),

    ItemCount INT

    );

    INSERT INTO dbo.TestPivot

    SELECT '4/1/2015','Benz' , 20

    UNION

    SELECT '4/2/2015','Benz' , -10

    UNION

    SELECT '4/3/2015','Toyota' , 10

    UNION

    SELECT '4/1/2015','Toyota'...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Issue with output parameter in stored procedure

    As I was reviewing my code, I found a mistake. I'm including a corrected version filled with comments on what the code is doing.

    Basically, I'm removing the cursor because...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Best design for OLTP tables

    sknox (8/6/2015)


    DrKiller (8/6/2015)


    I got the answer right, but with the wrong (or different?) theory...

    I was looking at the size of the CHAR value... I figured that because it is lower,...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Are the posted questions getting worse?

    TomThomson (8/5/2015)


    Eirikur Eiriksson (8/5/2015)


    ...and a bottle of gusano rojo mezcal to erase the "internal" memory, just in case

    😎

    That's crul and unusual punishment; anything involving a gusano (whether rojo or any...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Today's Random Word!

    Ed Wagner (8/5/2015)


    whereisSQL? (8/5/2015)


    Eirikur Eiriksson (8/5/2015)


    SQLRNNR (8/5/2015)


    pooping

    Potty

    Training

    Wheels

    Hot

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Are the posted questions getting worse?

    Eirikur Eiriksson (8/5/2015)


    SQLRNNR (8/5/2015)


    Sean Lange (8/5/2015)


    Ed Wagner (8/5/2015)


    Just don't forget to drop the database when the interview is over. 😉

    Or just create the objects in tempdb. :hehe:

    Or better yet -...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Parse String By Column Position

    For fixed width, SUBSTRING is the way to go. To reverse the process will be more difficult as you're creating different types of rows that would need validation when importing...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Are the posted questions getting worse?

    jasona.work (8/5/2015)


    On a side note, anyone want my summer cold? I'll even drive to your house and deliver it in person...

    Would it make my summer cooler? It's hot in...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Are the posted questions getting worse?

    I am entry level.First, I want to gain knowledge on internals of log shipping and internals of mirroring. So,Please suggest good books to start with

    I'm so tempted to say Books...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Are the posted questions getting worse?

    jasona.work (8/5/2015)


    GilaMonster (8/5/2015)


    Snippets and a whole pile of script files saved in DropBox and on a creditcard-shaped flash drive (which I need to update).

    And to get back on topic:

    "What book...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: Tuning a Stored Procedure

    I'll support what Kevin mentioned.

    There's a great room for improvement and I'm sure it wouldn't stop with this procedure as the whole database will have similar problems.

    I'd suggest that you...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • RE: How to grant user permission to view specific views

    You could create a Schema and grant permissions to the user on that schema so the user will have permissions to the views on that schema.

    Otherwise, you need to grant...

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2

Viewing 15 posts - 4,486 through 4,500 (of 8,731 total)