Are the posted questions getting worse?

  • DesNorton - Friday, July 7, 2017 2:45 AM

    Eirikur Eiriksson - Thursday, July 6, 2017 6:56 AM

    We can always make this a little more interesting
    😎
    DECLARE @Num INT =15;

    SELECT
      ISNULL(UNCOMPRESS(NULLIF(SIGN(@Num % 3),1) + 1181317754),N'')
     +
      ISNULL(UNCOMPRESS(NULLIF(SIGN(@Num % 5),1) + 1114995322),N'');

    ...and now the interviewer is crying😛

    Indeed.  You have introduced me to a new SQL function, yet I cannot find any documentation on it.
    Could you please point me in the direction of some documentation on the UNCOMPRESS function.
    I am only able to find info on COMPRESS and DECOMPRESS which are SQL 2016 functions.  However, the UNCOMPRESS seems to work on my SQL 2014 instance.

    UNCOMPRESS is an undocumented internal function that unpacks a  binary to a string format, does the same as CONVERT with the format parameter set to 0.
    This code I posted is obviously an exercise in obscurity 😉
    😎

  • My problem with FizzBuzz is I hardly ever have reason to use the symbols (like the modulo operator) in my current job. So I literally don't know them. I'd either need a BOL copy available to me to resolve the question or I'd do some over-engineered wacky CASE statement (after changing the INT to a NUMERIC so I could check the digits after a decimal) that would probably get me dropped from the interview queue.

    On the other hand, I also wouldn't be claiming to be a SQL developer or an expert. While I do some SQL development, I'm a DBA, not a developer.

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

  • If the candidate knows the syntax, great.  If not, I am expecting them to say something like "I do not use it often, so I do not know the syntax.  However, in pseudo code, I will do it like this."

    By the time a candidate gets to a face-2-face interview, they have already undergone a telephonic interview, and been given a spec to produce some WORKING code in a limited time period.  The spec provides a scenario, and table design, with some sample data.  It also provides a set expected outcome.

  • DesNorton - Friday, July 7, 2017 5:14 AM

    .....  The spec provides a scenario, and table design, with some sample data.  It also provides a set expected outcome.

    ....if only all the questions on this site did this 😀😀

    ________________________________________________________________
    you can lead a user to data....but you cannot make them think
    and remember....every day is a school day

  • Brandie Tarvin - Friday, July 7, 2017 4:48 AM

    My problem with FizzBuzz is I hardly ever have reason to use the symbols (like the modulo operator) in my current job. So I literally don't know them. I'd either need a BOL copy available to me to resolve the question or I'd do some over-engineered wacky CASE statement (after changing the INT to a NUMERIC so I could check the digits after a decimal) that would probably get me dropped from the interview queue.

    On the other hand, I also wouldn't be claiming to be a SQL developer or an expert. While I do some SQL development, I'm a DBA, not a developer.

    If I was the interviewer, I wouldn't mind telling you which is the modulo operator as it's an uncommon operator. Your alternative solution wouldn't drop you from the interview as it shows that you can find different options to achieve things. I'd also wouldn't ask this for a position that's not focused on development.

    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
  • One of the resumes I'm looking at says he has 20 years of "expert level experience." It's a pretty impressive resume, but the last job he had ended in May. Given the dearth of good DBAs in Jacksonville and the serious need for them (really, there are more jobs than there are good DBAs around here), my first thought was "Why is an expert over a month without a new job?".

    Major red flag there for me, given the current job market. If it were the other way around, few jobs but lots of skilled DBAs, I wouldn't be asking myself that.

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

  • Brandie Tarvin - Friday, July 7, 2017 5:42 AM

    One of the resumes I'm looking at says he has 20 years of "expert level experience." It's a pretty impressive resume, but the last job he had ended in May. Given the dearth of good DBAs in Jacksonville and the serious need for them (really, there are more jobs than there are good DBAs around here), my first thought was "Why is an expert over a month without a new job?".

    Major red flag there for me, given the current job market. If it were the other way around, few jobs but lots of skilled DBAs, I wouldn't be asking myself that.

    'Major red flag' seems like a bit of an overreaction. Maybe he went on holiday for a month, to recharge.

    The absence of evidence is not evidence of absence
    - Martin Rees
    The absence of consumable DDL, sample data and desired results is, however, evidence of the absence of my response
    - Phil Parkin

  • Brandie Tarvin - Friday, July 7, 2017 4:48 AM

    My problem with FizzBuzz is I hardly ever have reason to use the symbols (like the modulo operator) in my current job. So I literally don't know them. I'd either need a BOL copy available to me to resolve the question or I'd do some over-engineered wacky CASE statement (after changing the INT to a NUMERIC so I could check the digits after a decimal) that would probably get me dropped from the interview queue.

    There's a way to do it without modulo, using SQL's default of integer division. Not particularly clear what you're doing and why though.

    DECLARE @Num INT = 12

    SELECT (@Num/3) * 3 - @Num, (@Num/5) * 5 - @Num

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • UNCOMPRESS is an undocumented internal function that unpacks a binary to a string format, does the same as CONVERT with the format parameter set to 0.

    And I'm sure figuring out int representations of any 4-symbol world come natural to you.

    On an interview you'd easily put correct numbers into your code, just for amusement.

    _____________
    Code for TallyGenerator

  • Ed Wagner - Thursday, July 6, 2017 9:23 AM

    ChrisM@Work - Thursday, July 6, 2017 8:08 AM

    Ed Wagner - Thursday, July 6, 2017 7:59 AM

    Eirikur Eiriksson - Thursday, July 6, 2017 7:02 AM

    Grant Fritchey - Thursday, July 6, 2017 6:40 AM

    Thom A - Thursday, July 6, 2017 6:07 AM

    GilaMonster - Thursday, July 6, 2017 5:55 AM

    DesNorton - Wednesday, July 5, 2017 11:13 PM

    @Grant Fritchey

    I believe that congratulations are in order, sir.

    Or condolences, whiskey and a shoulder to cry on. 🙂

    How about a monkey Shoulder?

    Now we're talking!

    Should go nice with Ed's pig shoulder
    😎
    (from the smoker :D)

    It turned out great.  The shoulders had one of the best crusts I've ever developed, pulled easily and had great flavor.  The pork loin had a nice, deep smoke ring and, because I smoked it to temperature, didn't dry out at all.  My grand experiment was smoked macaroni and cheese and it got rave reviews.  All in all, the many-hour vigil was well worth it.

    A few weeks ago now I picked up the same smoker Neil Burton was raving about and since then I've had the chance to fire it up three or four times. Each time has been quite a learning experience, especially maintaining a low, steady temperature. Some of the results have been spectacular, but only the chicken so far. Whole legs soaked overnight in spices and maple syrup were particularly good smoked with oak logs, as was a large corn-fed chicken, spatchcocked.
    I'd love to know how you do a whole pork shoulder, it sounds just awesome - but if the small-ish joint I tried is anything to go by, you can say goodbye to crispy crackling, which is highly prized over here.

    I'm more than happy to share my recipe.  I have to get offline to go do some work on my house, but I'll get back online tonight.

    I never made it to a computer last night, but I'm done.

    I start with a whole boneless pork shoulder, patted dry.  I first rub it with kosher salt.  Other than flavor, this helps to bring water-soluble proteins to the surface of the meat.
    I then coat it liberally with a rub (a mixture of spices and herbs) - you can make it yourself or buy one.  I use a combination of salt, thyme, smoked paprika, chili pepper, black pepper and brown sugar.  Depending on your taste, you can add cayenne and other flavors.  I'm sure search engines will yield lots of rub recipes, but you'll learn over time what you and your family enjoys most.

    For the fire, I like apple wood because it provides good flavor, but also because I have a couple of large, old apple trees in my front yard that supply wood.  However, you can use apple, pear, hickory or just about any other smoking wood.  I find that in my smoker, oak tends to burn hotter than I like, so I avoid it.  The wood should be well-dried.  I start the fire and let it go for 20 to 30 minutes to get up to temp.  Plan on adding wood every couple of hours throughout the cooking process.  I also use a dual-probe BBQ thermometer (https://www.amazon.com/Ivation-Long-Range-Wireless-Thermometer/dp/B00ANCXJR6) to monitor the temperature of the air inside the smoker.  The controls on it could be better, but it works.  There are others available.

    I then set the shoulders right on the grate and let it go.  My target temp for the air inside the smoker is 200 F to 210 F.  I think 230 F is too hot.  I want to smoke it low and slow for that great smoked flavor.  I keep underlining the word air because I'm not monitoring the temperature of the meat.  The meat will be cooked to temperature long before the smoking is done, but I smoke by time.  I go for about 14 hours, but you can pull it after 12 hours if you're going to serve it a day or 2 later.  The reason for the very long time is that you want to break down all that connective tissue in the shoulder.  The long, low heat breaks down the collagen into gelatin.  It lets you pull it apart with two forks and produces that great texture that's famous in good BBQ.

    When it's done, take it off and let it rest, covered with aluminum foil, for an hour on the counter.  If you're going to serve it another day, cover it well and put it in the fridge.  To reheat it, add enough water to your roasting pan to come between 1/4 and 1/3 the way up the shoulder.  Add the shoulder and bake at 300 F for a couple of hours.  When done, don't throw away the water, which has been transformed into a smokey broth.  To "pull" the pork, simple shred it using two forks.  Depending on the crust (also called bark) you've developed on the exterior of the meat, you might need to cut it in half and pull it from the inside.  Be sure to pull or cut up the crust and mix it in with the rest of the pulled pork.  If you like, you can sprinkle some of the smokey broth over the pork and mix it in.  If not, it's a serious flavor base for homemade BBQ sauce.

    For shoulders, I go by time.  For cuts like pork tenderloin, I go by temp (145 F) because they'll dry out if you go longer.  Tenderloins can be reheated the same as the shoulder, but don't overcook them;  I use that same probe thermometer in the center of the tenderloin.

    To address the issue of sauce, for me, it's always optional.  I have a bottle or two available and let each individual decide for themselves at dinner.

    I know this is a long post with a lot of info and I hope it wasn't too long.  The key points are to rub it well, smoke it low and slow, let it rest and pull it while it's hot.  I know that 12 to 14 hours is a lot of time, but for me, it's worth it.  I learned a lot by doing it the first time.  Enjoy!

  • Brandie Tarvin - Friday, July 7, 2017 5:42 AM

    One of the resumes I'm looking at says he has 20 years of "expert level experience." It's a pretty impressive resume, but the last job he had ended in May. Given the dearth of good DBAs in Jacksonville and the serious need for them (really, there are more jobs than there are good DBAs around here), my first thought was "Why is an expert over a month without a new job?".

    Major red flag there for me, given the current job market. If it were the other way around, few jobs but lots of skilled DBAs, I wouldn't be asking myself that.

    Maybe interviewers keep asking him the FizzBuzz question. 🙂

    I wouldn't consider that a red flag.  There are all sorts of reasons he isn't employed yet; commute, type of work, or, as Phil said, maybe he's taking advantage of some down time.

  • Eirikur Eiriksson - Friday, July 7, 2017 4:41 AM

    UNCOMPRESS is an undocumented internal function that unpacks a  binary to a string format, does the same as CONVERT with the format parameter set to 0.
    This code I posted is obviously an exercise in obscurity 😉
    😎

    Thank you.

    So, who has a list of undocumented functions ????

  • GilaMonster - Friday, July 7, 2017 6:30 AM

    Brandie Tarvin - Friday, July 7, 2017 4:48 AM

    My problem with FizzBuzz is I hardly ever have reason to use the symbols (like the modulo operator) in my current job. So I literally don't know them. I'd either need a BOL copy available to me to resolve the question or I'd do some over-engineered wacky CASE statement (after changing the INT to a NUMERIC so I could check the digits after a decimal) that would probably get me dropped from the interview queue.

    There's a way to do it without modulo, using SQL's default of integer division. Not particularly clear what you're doing and why though.

    The idea in my head is to find out if there is a remainder after dividing by 3 or 5 or 15. If everything after the decimal is zero, I can assume it divides evenly. If there are other numbers, I assume it's not evenly divisible by these numbers.

    Of course, your simplier solution didn't occur to me. So now I'm feeling particularly ridiculous for trying to over-engineer this whole thing.

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

  • DesNorton - Friday, July 7, 2017 6:43 AM

    Eirikur Eiriksson - Friday, July 7, 2017 4:41 AM

    UNCOMPRESS is an undocumented internal function that unpacks a  binary to a string format, does the same as CONVERT with the format parameter set to 0.
    This code I posted is obviously an exercise in obscurity 😉
    😎

    Thank you.

    So, who has a list of undocumented functions ????

    I'm not even sure that Microsoft has one. :hehe:

    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
  • Luis Cazares - Friday, July 7, 2017 7:19 AM

    DesNorton - Friday, July 7, 2017 6:43 AM

    Eirikur Eiriksson - Friday, July 7, 2017 4:41 AM

    UNCOMPRESS is an undocumented internal function that unpacks a  binary to a string format, does the same as CONVERT with the format parameter set to 0.
    This code I posted is obviously an exercise in obscurity 😉
    😎

    Thank you.

    So, who has a list of undocumented functions ????

    I'm not even sure that Microsoft has one. :hehe:

    I know they haven't documented DBCC TIMEWARP(). Nowhere...

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

Viewing 15 posts - 59,161 through 59,175 (of 66,712 total)

You must be logged in to reply to this topic. Login to reply