19 June 2025

SELECT *
FROM TABLE1 
WHERE ID NOT IN (
    SELECT ID
    FROM TABLE2
)

When I ran the above query I know the condition will give me the results, because the data exists in the TABLE1 which is not in TABLE2. But I didn’t go any results. I got surprised. After I a while I found out the issue.

So the reason is that ID column in the TABLE2 have null values. If any value of ID in the subquery is NULL, then the entire NOT IN clause fails to match anything. This is standard SQL behavior because NULL makes the whole comparison unknown.

Solution:

  1. You can use NOT NULL condition in the sub-query as below:
SELECT *
FROM TABLE1 
WHERE ID NOT IN (
    SELECT ID
    FROM TABLE2
    WHERE ID IS NOT NULL
)
  1. Use NOT EXISTS:
SELECT *
FROM TABLE1 T1
WHERE NOT EXISTS (
    SELECT 1
    FROM TABLE2 T2
    WHERE T1.ID = T2.ID
)

The NOT EXISTS will automatically handle null values and safer to use.

References

StackOverflow, Geeks for geeks

26 May 2025

I often found that Ctrl+Alt+Delete unhangs the Windows PC. I googled why?

The nutshell answer is : Ctrl+Alt+Delete is a secure attention sequence (SAS) triggers a system interrupt, effectively forcing the computer to respond. This is directly handled by the Windows operating system kernel. That means it can bypass most of the stuff that’s currently running (including frozen apps or even some parts of the graphical interface).

Cool to know this.

19 May 2025

I just found two tools:

Thunder and Unicorn mixed by Emoji Kitchen

18 May 2025

I don’t search for things as much as I used to. These days, I just go straight to ChatGPT. I don’t feel like Googling and clicking through multiple pages to find the best answer. I ask ChatGPT, and most of the time, the results are satisfying.

I’ve heard that traditional Google searches are declining. But now, they’ve introduced AI Overviews at the top of their results. I think it’s a good idea—because we get a quick summary of what we’re looking for, along with links to other websites. Yes, I think it’s a good move.

Google AI Overview for my theme Lightbi

12 May 2025

Install Material Icon Theme

In settings.json:

"material-icon-theme.folders.associations": {
  "folder-name": "Home"
}

folder-name is the folder name and Home is the icon. You can find the files and folders icons in here.

11 May 2025

To make a sticky footer in the Bootstrap you can use the below.

<body class="d-flex flex-column min-vh-100">
  <main class="flex-fill">
    <!-- Your page content here -->
  </main>

  <footer class="bg-dark text-white text-center py-2">
    <!-- Your footer content here -->
  </footer>
</body>
  • d-flex flex-column min-vh-100 on : makes the body fill the viewport and act like a vertical Flexbox container.
  • flex-fill on : makes the content area take up all available vertical space, pushing the footer down.
  • footer: stays at the bottom even with short content.

10 May 2025

To install or update Hugo extended using HomeBrew, you can use the below,

Install the extended version:

brew install hugo@extended

Or if you already have it and just want to upgrade:

brew upgrade hugo@extended

Check the version to using hugo version.

9 May 2025

One of the main topics discussed in the seminar I attended was modernizing legacy applications.

Legacy applications are typically monolithic in nature, making it difficult to scale or integrate new features quickly. The monolithic apps ruled the software industry for a very longer time, but now people are moving (already many moved) to its great alternative, the microservice architecture.

I’ve come across monolithic applications that are tightly coupled with environments like Oracle or .NET, where growth can become a painful process. Over time, these systems tend to become slow, expensive to maintain, and resistant to change.

Monolithic and microservice architecture

7 May 2025

In the feed page I need to hide the dotted line in the mobile screens. So here you can see how its can be done in Bootstrap.

  • d-none d-md-flex: shows only on md and up (desktop/tablet)

  • d-block d-md-none: shows only on mobile

  • text-nowrap: prevents text from wrapping

<div class="mb-3">
  <!-- Desktop layout -->
  <div class="d-none d-md-flex align-items-center">
    <a href="{{ .Permalink }}" class="text-decoration-none fw-medium me-2 text-nowrap">
      Sample heading
    </a>
    <div class="flex-grow-1 border-bottom dotted-line mx-2"></div>
    <p class="text-muted small text-nowrap mb-0">Date</p>
  </div>

  <!-- Mobile layout -->
  <div class="d-block d-md-none">
    <a href="{{ .Permalink }}" class="text-decoration-none fw-medium d-block mb-1">
      Sample heading
    </a>
    <p class="text-muted small mb-0">Date</p>
  </div>
</div>

6 May 2025

Avinash is sharing some cool facts about SQLite.

  • SQLite is the most deployed and most used database. There are over one trillion (1000000000000 or a million million) SQLite databases in active use.

  • SQLite is likely used more than all other database engines combined. Billions and billions of copies of SQLite exist in the wild. It’s everywhere.

These are mind blowing, have a look into that.

Article link