views:

1070

answers:

7

A friend of mine uses in his company an ERP software written in PowerBuilder. Unfortunately the (one and only) developer is going into retirement soon. My friend really likes the software and wants to keep using it for at least ten more years, so my friend decided to buy the source code.

He wants to start a business to maintain the software and develop new features. At the moment there are probably about 50 installations of that software out in the wild and he already knows of a bunch of potential buyers.

Now he's searching for a developer and asked me... I did a little C/C++ programming, a bit of VB and a bunch of other languages but in the last years I earned my money by writing Java web applications. From what I read, PowerBuilder looks quite antiquated to me, there are hardly any tutorials out there, no open source frameworks, awkward version control, didn't even read about any test frameworks. People here on StackOverflow say they hope, the language/IDE is dead. Additionally the code I'd maintain is completely undocumented and untested.

Do you think it's possible, for someone who never even heard of PowerBuilder before, to maintain such a software?

EDIT: okay, thanks for your answers. We decided to kick the old application completely and re-write it in an up-to-date-language.

A: 

I worked on powerbuilder quite sometime back, version 6.5 Its quite easy to use and one can compare it to VB. I feel it would be quite easy to maintain an application and do small fixes and enhance the system. There are quite a few companies that still use powerbuilder and maintain old application.

Dheer
+3  A: 

Yes, it's possible. Powerbuilder is not a hard language to pick up, particularly if you have used VB already.

The Powerbuilder community is far smaller than what you may be used to with e.g. Java, but it does exist. The best place (other than SO!) to ask questions are the sybase.public.powerbuilder.* newsgroups.

For unit testing, try PowerUnit, and for source control, you can use Subversion via PBSCCProxy, TamTam SVN SCC, or PushOK SVN SCC proxy.

It's been a niche language for a long time now. In my opinion this is due the upfront cost of the tools required, which is essentially blocking anyone new from considering it.

The future is reasonably bright though: Sybase is flourishing, committed to PowerBuilder, and regularly announcing progress towards version 12, which will be a full .NET language like C# and VB.NET, and will ship with an IDE based on VisualStudio. You will be able to directly migrate your code to version 12, no rewrites required.

Colin Pickard
There will be PLENTY of refactoring to do before going to PB12.
Zerofiz
The comment about refactoring to go to PB12 is uninformed, I'm afraid. There is nothing intrinsic about PB12 that will require refactoring. I've migrated apps to pre-releases of PB12, even to WPF targets, with no code changes at all. That's not to say *no* changes will be required, say if your app uses features that aren't supported anymore (e.g. right clicks on commandbuttons). That's also not to say refactoring won't be required to leverage new features, but that's true in leveraging almost any new features. Sybase has some good webcast recordings about PB12 worth looking at.
Terry
A: 

Yes, you would certainly be able to learn PowerBuilder. Whether you want to is a question only you can answer, though.

I used PowerBuilder for many, many years (versions 4 through 9). There were parts I truly liked. It's a great way to build business applications. It's object-oriented and the DataWindow is a wonderful technology.

But it has its bad points as well. The IDE is archaic. The code editor is simplistic (no code completion, for example). Integration with source control is annoying and the community is pretty small. And it's Windows-only.

There is a magazine (PowerBuilder Developer's Journal - SYSCON), but it's pretty thin these days. Sybase does appear to have some neat things up their sleeves for future versions of PowerBuilder, however.

Personally, I liked it enough that I would go back to it if an opportunity arose.

Paul Lefebvre
+3  A: 

Yes, any competent programmer, and even some not-so-competent ones can use PowerBuilder. However, I'd disagree somewhat with one of the earlier answers. It is different from pre-.Net VB in one sense: it supports true OO principles (encapsulation, inheritance, and inclusional polymorphism [but not operational polymorphism via Interfaces as in C# and Java]). Classic VB didn't have inheritance.

Other answers from Paul Lefebvre and Colin Pickard are correct: PB is still alive though more of a niche language than it used to be, and Sybase is indeed moving it in the direction of .Net. As for source control, PB supports some interfaces (we use it with VSS) but I'm thankful for Colin's nice set of links, which may come in handy in the future.

Frameworks: the most common one is the PowerBuilder Foundation Class, which Sybase open sourced years ago.

My caveat to you is this: I said above that people didn't have to be particularly strong programmers to write PB. PB is easy to learn but takes time to master. It had its biggest days in the late 90's, when anyone that could double-click on a Windows icon to launch an app thought they were a programmer. Despite truly supporting OO, most PB apps are not well designed and well written apps. They're usually total hack jobs (a criticism of the lack of experienced developers and immaturity of software development at the time, not of PB itself, which is still a very powerful tool). If you are inheriting a code base that is truly easy to maintain and manage, you are in the minority. PB code can nearly always be classified as legacy code. The good news is that there is plenty of challenge. You will have many quick-win refactoring opportunities and plenty of production support.

Bernard Dy
A: 

I started my career as a PowerBuilder developer, but quickly changed to java and python, as soon as I realized PB was almost a dead language.

Also, even if there are tools that can be used to apply programming "good practices", they are not widely known and somewhat expensive, so I've had to work even without version control (!!), left aside automated testing or continuous integration.

It is a language in which almost anyone can start to build usable apps in a short period of time and with little training, and the apps are built really fast, in contrast with java, that demands a period of learning until a developer can be productive, and even then, a webapp takes time to be developed.

But the payback is with maintenance, that quickly becomes a nightmare. Even a minor change in the database like a type change in a database column can destroy every datawindow (the PB ubiquitous data-access component) that refers to it.

It's pretty much similar to VB, in that as almost anyone can develop applications in it, with very little programming knowledge, the average quality of applications is very low, with unmanageable database coupling and plagued of bad coding practices.

My advice is not to build a Developer career in such kind of language unless the money justifies it, and in that case, continue training yourself in alternative technologies as a "plan b" to not become obsolete along with the language.

And always work to keep your coding and problem solving skills "in good shape" as this kind of language does not help in that.

Sam
You sir, are an idiot.
Zerofiz
+2  A: 

With the risk of sounding biased I think PB is one of the better RAD tools out there and the new version PB12 scheduled next year will make it once again interesting since it uses the VSShell from Visual studio as its new IDE (Intellisense etc). I am currently busy working in the compiler team adding all the .NET goodies to PowerScript that one is used to from C# like delegates, interfaces, attributes etc but still keeping the language simple to use. PB is also one of the few development platforms that provide migration from older to newer versions and the new PB12 is no exception. The applications generated by PB12 will be modern looking using WPF and later Silverlight for post PB12 so I am quite excited. I am not a PB developer per se (C++) but I still think for producing C/S apps fast its hard to beat.

Anders K.
A: 

It depends on the technical quality of the original application whether migrate to another language is feasible at all.

BEFORE YOU READ MY "PB IS GOOOD": I'm a PowerBuilder developer since '93. PowerBuilder is very much alive and kicking. Yes a lot of people left the language shortly after the millenium but quite a few have returned later. No I don't earn money selling PB!

The biggest differentiator between PowerBuilder applications and any other tool is the DataWindow technology. It is such a strong tool in the hands of an knowledgeable developer. Examples: Dynamic creation of optimal SQL for INSERT/UPDATE/DELETE. Close to every property of everything can be an expression using data in the DW buffers. DropDown DWs are so cool. DW and the rest of PB is truly DBMS independent!

How important is code completion when many of my DataWindows only need 4 function calls anyway?

  • Define DB connection >> dwData.SetTransObject(SQLCA)
  • Read all data from DB >> dwData.Retrieve()
  • Write data to DB >> dwData.Update(true, false)
  • Reset when committed >> dwData.ResetUpdate( )

My bet: If the original developers knew how to really exploit DataWindows - any estimates you make on migration to Java or C# will not even come close to what will actually happen. If they didn't: The application is just another application that does data binding differently than your new tool.

What you loose when using PowerBuilder? You need to accept that the 4GL and its VM are designed as they are - no access to the source code of the VM so you can't make your own VM customizations. No turning off the NULL support to increase speed. No changing the event order by rewriting the VM's event manager. 4GL means less lines of code. DataWindow means a lot less LOC. 4GL means less geaky bit tweaking.

/MicKr- BTW: PocketBuilder is PB for Windows Mobile - cool idea!

Thanks for your answer! We decided to rewrite the application, but mostly due to the lack of documentation and tests. I took a look at the code and it was a mess. I'd have given PB a chance but not on that code basis...
Olvagor