RPG and DB2: The Future Is Now
Really, there is no problem to learn RPG, especially since V5r2, when it became standard procedural language. And, if your applications based on iSeries, of course RPG is language of choice for server side processing. One point that I disagree with Joe it's about SQL. I think that SQL is the best database tool (not for all programming problems, but for database ones). When I say "SQL", I mean not only SQL statements, but also embedded SQL and SQL control statements, that both are ANSI standard of SQL (by the way, example from Joe's article normally should be written in SQL in the same manner as in RPG, using embedded SQL or by using control statements, that include "if" statement). There are a lot of things that belong to server-side processing that very hard and sometimes almost impossible to do with native I/O. It includes dynamic SQL, but not only. It takes about month to become quite knowledgeable in SQL. I strongly believe that any serious iSeries programmer must know and must use SQL. But... I think the problems with SQL on iSeries is not performance as is (IMHO, in most cases performance of single record access is not the issue, especially when using N-tier architecture with some kind of stored procedures, and in multi-record processing SQL usually the winner, may be after some hours of tuning :-) ). One of the problem is very bad RPG compiler support for embedded SQL statements. While that problem may be aesthetic issue only, the biggest one is a lot of critical bugs in SQL engine - fully spectrum from poor performance till wrong query results. In our shop we using SQL very extensive, and in my bad experience I had "bugged" statements that a little bit complicated than "select * ...". It's really nightmare - to understand what's wrong with your statement, to find PTF that should fix that, to do IPL, and after all that to see that some other program that usually took minutes to processing now takes days! RPG with native I/O always predictable, so in mission critical applications on iSeries, by now, it may be more clever to use it. But I still believe, that one day DB2 on iSeries will became really strong and well performed, so I continue to use SQL. I apologize for my bad English. Vladimir.
Really, there is no problem to learn RPG, especially since V5r2, when it became standard procedural language. And, if your applications based on iSeries, of course RPG is language of choice for server side processing. One point that I disagree with Joe it's about SQL. I think that SQL is the best database tool (not for all programming problems, but for database ones). When I say "SQL", I mean not only SQL statements, but also embedded SQL and SQL control statements, that both are ANSI standard of SQL (by the way, example from Joe's article normally should be written in SQL in the same manner as in RPG, using embedded SQL or by using control statements, that include "if" statement). There are a lot of things that belong to server-side processing that very hard and sometimes almost impossible to do with native I/O. It includes dynamic SQL, but not only. It takes about month to become quite knowledgeable in SQL. I strongly believe that any serious iSeries programmer must know and must use SQL. But... I think the problems with SQL on iSeries is not performance as is (IMHO, in most cases performance of single record access is not the issue, especially when using N-tier architecture with some kind of stored procedures, and in multi-record processing SQL usually the winner, may be after some hours of tuning :-) ). One of the problem is very bad RPG compiler support for embedded SQL statements. While that problem may be aesthetic issue only, the biggest one is a lot of critical bugs in SQL engine - fully spectrum from poor performance till wrong query results. In our shop we using SQL very extensive, and in my bad experience I had "bugged" statements that a little bit complicated than "select * ...". It's really nightmare - to understand what's wrong with your statement, to find PTF that should fix that, to do IPL, and after all that to see that some other program that usually took minutes to processing now takes days! RPG with native I/O always predictable, so in mission critical applications on iSeries, by now, it may be more clever to use it. But I still believe, that one day DB2 on iSeries will became really strong and well performed, so I continue to use SQL. I apologize for my bad English. Vladimir.
Comment