There’s one annoying problems with my Mac laptop. When I’m at work, I connect to external monitor and work on both built-in monitor on my laptop and the external monitor. When I go home I unplug the external monitor, close the lid and let the laptop goes to sleep. Once in a while, when I [...]
One of the golden rule of programming is to know about the function you are calling. You need to know what parameters it takes and what return values and type it gives back. For the most part, it’s not too hard to find that out. For MySQL, however, I found that it’s not always easy [...]
During development cycle, I often come to a case where I need to compare two tables whether they are the same or not. For example, if you already have a running script that outputs to a database table in production that was written sub-optimally and you need to improve it. You want to make sure [...]
This is pretty simple to do. It’s also very usable if you just want to compare 2 files or different sections on the same file. Here’s what you do while in vi or vim.
Split screen horizontally
The above code will split vi horizontally like the screenshot below. You can also supply an optional filename. If you [...]
Have you ever done SHOW FULL PROCESSLIST on MySQL and found that there are some queries that has been running for a long time? Then you tried to find out from where the query was initiated so that you can debug those script only to find out that there are many similar queries from different [...]