Imagine the Physical World

  • Comments posted to this topic are about the item Imagine the Physical World

  • I love the way you framed this — treating digital work as if you had to do it yourself in the physical world. It’s a mindset that makes optimization feel less abstract and more tangible. Let me give you a practical example with a bit of humor:

    Think about a SQL join. In the database world, it’s just a neat operation that combines rows from two tables. But imagine it physically: you’re at a giant dinner party, and someone says, “Hey, can you seat everyone who ordered chicken next to someone who ordered wine?” Suddenly, you’re running around the banquet hall with a clipboard, matching people up, dragging chairs, and rearranging tables. That’s a join. And if it’s a cross join? Well, now you’re trying to seat every single person with every single other person. You’ve basically turned the dinner party into speed dating chaos.

    The humor is that in SQL, it’s just milliseconds of CPU time. But if you picture yourself actually doing the work — sprinting between tables, sweating, apologizing to guests — you start to appreciate why an efficient query matters. You wouldn’t want to run a cross join at a wedding reception unless you enjoy chaos and lawsuits.

    That’s the beauty of this perspective: when you imagine the physical effort, you naturally start asking, “Is there a smarter way to do this?” And that’s exactly how better solutions are born.

     

    images (1)

    • This reply was modified 1 weeks, 2 days ago by naumon765.
  • Excellent and really like these.

  • Indeed. This is physical work for the CPU, but we dismiss it because it's fast. and because for small data sets, it appears instantaneous.

    Picturing little men and women in the computer running around doing the work is helpful. We want to make their job easier.

  • Michael.Beeby wrote:

    Excellent and really like these.

    Thanks, and glad it resonated.

  • A few days ago I explained the concept of an untrusted foreign key constraint to a sales person from a vendor:

    All doctors in a hospital should hold a doctorate. However, if you expand—hiring 50 new doctors and briefly suspending this check due to time constraints—you cannot be certain that a charlatan hasn't slipped in if you fail to verify actual qualifications retroactively (using WITH CHECK) and instead simply reactivate the rule for future hires (using CHECK CONSTRAINT without WITH CHECK).

    For technical people: you have to use this syntax

    ALTER TABLE [dbo].[orders] WITH CHECK CHECK CONSTRAINT [FK_orders__customers];

    but often the additional WITH CHECK is forgotten since it seems to be redundant and is optional

    God is real, unless declared integer.

  • Walk a mile in someone else's shoes!

    A senior infrastructure colleague used to describe people's attitude to infrastructure as being paid for in wooden dollars.  To non-infrastructure people, the real cost was invisible. They'd been asked to deliver something that was expressed in functional requirements, with the NFRs not considered.  There was no concept of the cost of infrastructure.

    This is why I'm keen to make operational metrics and costs visible to tech teams and also teams dependent on tech teams.  I see people trumpeting a 5% increase in revenue, woefully unaware that costs have gone up 10%.

    When  I started working with SQL Server, we were taught to look at query costs and a range of Perfmon stats because these were our alarm bells. For us as DBAs, these really mattered.  I'm not convinced we communicated this effectively to our other technical colleagues.  I'm near the end of my career, and I'm convinced that one hell of a lot of problems stem from failure to communicate.

    There was a TV series called "Back to the floor".  This was where a company CEO or owner was put anonymously into a junior role to work for a week or two.  It was revealing stuff, and some good results came out of it.

    For my father's generation, you couldn't become a director of a company unless you had worked as a manager in other departments.  You couldn't work your way up a single discipline.

  • Thomas Franz wrote:

    A few days ago I explained the concept of an untrusted foreign key constraint to a sales person from a vendor: All doctors in a hospital should hold a doctorate. However, if you expand—hiring 50 new doctors and briefly suspending this check due to time constraints—you cannot be certain that a charlatan hasn't slipped in ...

    Not bad. That's a good way to put the checks in place. I might expand to note the effort to make the check, vs only make future checks. The validation is good, but also the cost is helpful

  • had an idea  .. working in vast amounts of companies

    a small set of people handle "end to end"

    meaning from HR to Production Support to Development to meetings with clients COO stuff CEO stuff

    Example : each ticket or development the same set of people sit finish it off in seconds or minutes

    its sort of radical than the the traditional heirarchy based system

     

    But extremely curious and interestingly interested how it works out in REAL LIFE

    images (1)

     

     

    • This reply was modified 1 weeks, 2 days ago by naumon765.
  • I agree that visualization of the work done by a computer can really bring a lot to understanding.

    Here's a part of the tube that I have had out there for a very long time.  This part is specifically about page splits.  I generated the graphics just using Power Point... not AI.

    https://www.youtube.com/watch?v=rvZwMNJxqVo&t=972s

    The rest of the tube has a bunch of similar animations.

     

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • hi Jeff

     

    took a look at your YOU TUBE video

    nice extremely dense thick stuff

     

    images

Viewing 11 posts - 1 through 11 (of 11 total)

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