Pragma 5 and the Internet


Last update:
December 15, 1999

I have been recently asked whether we foresee in the future the possibility to get data from a Pragma application and use that data online in a website.  For instance, say that a company produces cookies and keeps its inventory in one or various PFM files.  Now the company plans to make a web site listing all the cookies it produces, complete with how many are in stock.  The idea is that anyone authorized can electronically order their favorites cookies and have them shipped with the least amount of human intervention.

Will this be possible with Pragma 5?  Let me kill any suspense instantly and tell you that this is already possible today, and as a matter of fact is already done by Ron Fish in Salt Lake city.

Before I go into the details of how to do it let me first tell you of how you do not want to do it.  You do not want to put your precious PFM or Btrieve files online because of security concerns.

Let me make a small digression on security.  When we think of web security we almost always conjure up images of pimply nerds that write viruses to cause havoc, break into web sites to delete data and amuse themselves with such idiotic behavior.  Right?  Wrong.  The most dangerous security breeches are the ones that you are not aware of.  From your competitor, for instance.  Wouldn't he love to break into your site and get hold of your customer list?  Or say, once a month see which cookies are your best sellers so that he can beat your offers?  When putting data on a web site this kind of security problems must be your first concern.  And if you make your precious PFM files accessible on the web, you are inviting trouble.  What about firewalls and similar goodies?  They are expensive and difficult to manage.  Also, they CAN be breached. The U.S. government, including the CIA has had their sites penetrated.  Remember the KISS principle.

The solution is simple.  You write in Pragma a program that creates a text file of the data that you want to make accessible.  Even if you have 10'000 inventory items such a file is created in a few minutes max.  More than likely in a few seconds.  Then with a System Call transfer the data text file (with FTP) to your web server.  That text file (or files) contains only the strictly necessary data.  If you want to indicate say the number of items in stock and are worried about obsolete data, have Pragma create and send the text file (files) once every hour or 15 minutes, if necessary.

Once on the web server, these text files are then read by the Pearl or Java program on the web page where visitors place orders.  I consider this to be an elegant, safe and inexpensive solution.  And it works since it has been already implemented by Ron.  Of course it means that you or somebody must write a small Pearl or Java program for the web site.  But this must be done anyway.

OK.  So your web server has received an order for a deluxe box of cookies to be sent to Aunt Alice.  What now?  The easiest way to handle an order is to have the same Pearl or Java program that receives your order send you an e-mail with the order.  Back in the home office of the cookies factory you can then process the incoming e-mail orders how you wish.  You can even read them with a Pragma program and then automatically process the order and then, if that order cleaned out your inventory, generate a new inventory text file and send it to the server.

Any web program that allows ordering or reading a data base will require a Perl, ASP or Java program. Approximately 80% of the world's servers use UNIX.  Almost all servers have Perl - which works on any O/S. Most now have Java as well. ASP is primarily used just for NT servers which have the worst security. Additionally, it is EXTREMELY important that the ISP (Internet Service Provider) server that your client uses has SSL security. Many ISP's don't have this which makes ordering information, including credit card data, open for pirating by anyone.  The easiest way to test if an ISP has SSL is to simply add an "s" to the http address:  https://www...  If it goes to a secure site, they have it. If not, they don't.

Ron Fish is our resident expert on interacting with the web.  He writes the server programs in Pearl, since he considers Pearl more universally accepted than Java.  Please note that Ron does this programming for a living and that answering questions on web programming is not part of Pragma support.  Should you want to use his considerable expertise in these matters, you must make your own financial arrangements with him.

Please let me know if you have any comments, suggestions or questions.

 

lip_tec3.gif
t_p5int.htm