2025-12-31
Yet another year in The Data Warehouse - 2025
2025-01-01
Yet another year in The Data Warehouse
2001 I created the data warehouse. The reason was to help a purchaser with a forecast report. It would have been easy just to create a paper report from the mainframe ERP system I created 1979, but I wanted to create a better tool for business analyzing and reporting, but I did not get founds to by any software, so I had to create a system from what I had and free software. I was pretty sure the data warehouse would be around for some ten years or so, but not for twenty three years, still counting! I some years ago wrote that the swan song for the data warehouse had begun, it is a very long tune indeed. I would not be overly surprised if I can celebrate a twenty fifth jubilee next year.
Of course I have not done The Data Warehouse alone, I made the infrastructure and the tools to import and massage the data. Most reports, marts, apps etc, have been made by others, not to forgot the operations. A data warehouse is a complex piece of machinery that needs supervising, maintenance and tinkering 24x7.
For this year I expect to finalize the PHP 7.4 to 8.4 conversion, this is my worst job ever and I have done a lot of really bad jobs during the years. This upgrade is something I'm forced to do, I really did not want to do it, but you do not argue with IT security. I also need to upgrade MySQL. Both these things should have been done ages ago. But now I have to do it boring, boring, boring.
When I retired I said 'From now on I only do fun things that interest me.' Since then I only do boring things or even worse, I had to maintain some SharePoint apps for some years, that was hopefully the low moment of my years in IT. I have for some ten years wanted to start D programming, but I can not muster the energy needed to learn D. I also have looked at Raku but have not started yet. And now I'm looking at Java script again! I really hope I can muster energy this year to restart my career, I'm still only seventy one.
2024-08-25
Trick from Walter Bright
Yesterday I learnt a neat syntactical trick from Walter Bright founder of the D language.
do
{
if (x) break;
if (y) break;
if (z) break;
hotPath();
} while (0);This is very useful if you like me often have more than one return from functions and subroutine. For many reasons you only want one return point. This little trick may come handy in some situations.
I recommend the D language page https://dlang.org/ if you are interested in Programming in general. I found the discussions of the D language itself very interesting.
2024-01-01
New year new currency rates
| STATUS | |
| DISTINCT_VALUES | 1: AVG AND EOP HAVE DIFFERENT VALUES FROM LATEST PERIOD |
| NEW_RATES | WARNING: TOTAL NUMBER OF EXCHANGE RATES IS DIFFERENT FROM PREVIOUS PERIOD |
| MAX_EOP | 1: EOP SINCE LATEST PERIOD HAS NOT INCREASED MORE THAN 20% |
| MIN_EOP | 1: EOP SINCE LATEST PERIOD HAS NOT DECREASED MORE THAN 20% |
| MAX_AVG | 1: AVG SINCE LATEST PERIOD HAS NOT INCREASED MORE THAN 20% |
| MIN_AVG | 1: AVG SINCE LATEST PERIOD HAS NOT DECREASED MORE THAN 20% |
| MAX_EURX | 1: EURX SINCE LATEST PERIOD HAS NOT INCREASED MORE THAN 20% |
| MIN_EURX | 1: EURX SINCE LATEST PERIOD HAS NOT DECREASED MORE THAN 20% |
| DISTINCT_DATE | 1: EOP,AVG,EURX ALL HAVE A NEW DATE DIFFERENT FROM LAST PERIOD |
| ACAB_DATE | 1: ACAB HAVE NEW DATE FROM LATEST PERIOD |
| ACAB_VALUE | 1: ACAB HAS DIFFERENT VALUE FROM LATEST PERIOD |
| BUD_DATE | 1: BUD HAVE NEW DATE FROM LATEST PERIOD |
| BUD_VALUE | 1: BUD HAS DIFFERENT VALUE FROM LATEST PERIOD |
| CURRENT_PERIOD | 1: LATEST PERIOD IN EXCHANGE_RATE IS CORRECT |
2023-12-31
Yet another Year
(A new promising guy have just stepped in to replace Hans.)
I have started upgrade the Data Warehouse from PHP 7.4 to PHP 8.1, (the plan is to go to PHP 8.3). This turned out to be tidious and much harder than I had anticipated. PHP is not very PHPish anymore. All the nice features/defaults I used to silently take care of conversions, bad and buggy code now issues tons of warnings, deprications and errors. This upgrade takes a long long time, eventhough the code in general is pretty good and well documented, sometimes it is hard to remember the reason behind code written in PHP 4 twenty years ago. Upgrades to new PHP versions have been simple until now, (PHP 7.4 forced me to rewrite the entire SAP interface, apart from that very little problems). This time I will remove not only errors, but depreciations and warnings as well.
This year we upgraded MySQL to vs 5.7, next year the plan is to upgrade to vs 8.
Other things.
After years of procrastination I have now almost finalized Rey Valeza's D language web tutorial. It is a really great web programming tutorial, if you are an experienced programmer without 'web experience' and like to get your hands dirty this is a tutorial for you. Next I see if I can find a D language tutorial on creating a 'bare metal' program. I want to be a D programmer, I am not today, I cannot even read D code.
At last a happy new year๐
2023-10-11
Import SAP data into MySQL with little effort
This morning I stumbled upon a SAP import script written in my Integration Tag Language. The script is a little gem, it is probably written about 2008.
The script includes all code needed exporting data from a SAP rfc function into Mysql (including defining an import table in Mysql. I have removed parts not necessary for showing the complete export process from beginning to end.
The script starts defining the workflow, run time parameter and symbolics:
(The run time parameter sap points to a SAP system.)
Next we have two jobs truncate & getSapData:
1 Truncate the result table if it exists (only for full load)
2 GetSapData (the little gem)
This job is packed with relevant and succinct logic for SAP data extraction.
(I added some comments for your convenience.)
That’s it.
The script is a complex parallel process expressed in concise and well defined code.
I have not written the script myself, but I’m proud of the Integrated Lag Language (ITL) which I wrote in 2006 that makes this script possible.
If you have a better way of importing data from SAP, please drop me a note.
If you are the script author you must give me a call๐