May 31, 2023

SQL Creating SQL

I needed to update a relational database table’s values from another database table referencing each other and came out with an interesting way to solve this. The ideas is to generate other SQL as text as output, in my case a series of update statements. I guess an example could help to explain the whole thing better. We have 2 tables: CREATE TABLE FIRST (ID INT, COL1 VARCHAR); And Read more

March 9, 2022

datediff

I’ve been trying to quit smoking and I wanted to have some feedback on how much time passed after the last cigarette i smoked. So i started developing a program to tell me how much time passed from a saved date and time in a human readable format. The first thing I did was to write a python program to save and calculate the difference from the saved timestamp. It’s pretty easy, just Read more

September 6, 2020

Git Repos

I’ve changed a bit my stuff online lately. This blog it’s one of the changes, It uses Hugo to generate a static site from markdown pages using the nice kiss theme. You can find the source code for it here The other is the code repository, I used a gitea instance, I’ve changed now my personal repo to be https://git.scompo.it. There you can find an instance of git-web. Both https://git.scompo.it and https://blog. Read more

© Mauro Scomparin 2020 - 2023

Powered by Hugo & Kiss.