php[architect] logo

Want to check out an issue? Sign up to receive a special offer.

Oracle PHP Generator

Posted by on April 19, 2010

Oracle PHP Generator is a tool from SQLMaestro which automatically generates a PHP user interface for Oracle databases. This generated code can run on any PHP 5 server with the necessary extensions. In its free version, the generator is capable of implementing all the basic features of database access such as querying, filtering and sorting of results, and even files upload.

The basic idea

Thanks to the wide support by hosting services, PHP can run nearly everywhere in the web and has a stable and high performance driver for Oracle databases.

This approach to user interface is sound: the Oracle development model prescribes to keep all the business logic in the database via its PL/SQL language, an extension to the standard ANSI SQL. Every database vendor has its proprietary extensions to SQL, but Oracle and PL/SQL are famous for their extended set of features and expressive power. Similar PHP code generators are available for other database vendors, which often lack the necessary support for the encapsulation of business logic.

Issues with generation approaches

Programming without programming is an old idea and has never been a full success. In addition to the standard graphical customization, there are many aspects of the development of the user interface which deal with presentational logic, which does not belong to the database side and should be dealt with by the UI layer.

For example, the localization of dates and times in a format convenient to the end-user it’s a common case of presentational logic: the underlying representation in the database it’s always the same, but the data is translated for the sake of a smooth user experience. Oracle PHP Generator, at least in its full version, supports many of these caveats, but one can never be sure that the generated interface will support all the needed features. Generated code should never be modified by hand, due to the issue of keeping customizations during a subsequent regeneration (performed for example because of a change to the database schema.)

The tool

This particular execution of the UI generation idea is a bit off track. For example, the product runs only on Windows via an user interface. This makes it difficult to use it in a continuous integration cycle, or in any kind of automated process. The products of code generation have to be kept in sync with the back-end they refer to.

Of course Oracle PHP Generator is the right product for data-driven applications, which work mostly with CRUD and orthogonal requirements such as authentication and access control, and leverage the Oracle support for business logic in the persistence layer — if you happen to like it — avoiding unnecessary duplication. However, like all generated UI products, it shows its limits when it comes to support unusual features in the UI.


Marco is the keeper of keys and Chief Garbage Collector at Blue Parabola. He can be found on Twitter as @mtabini.
Tags: , , , ,
 

Responses and Pingbacks

Code generation is a wrong way because you have to regenerate the code repetitively. You also can’t change the generated code because it would be overwritten next time.

Better approach is to examine the live database by a script and optionally customize the output. This approach is used by Adminer Editor – http://www.adminer.org/editor/. It is currently available for MySQL but there is an ongoing development for other database systems.

[…] access such as querying, filtering and sorting of results, and even files upload. For more info- Oracle PHP Generator | php|architect Reply With Quote   + Reply to Thread « Previous Thread | […]

Leave a comment

Use the form below to leave a comment: