Working with spool files on the AS400 in Coldfusion

I wanted to put this code out here just to help anyone out who try's to get started with the IBM toolbox for Java.  This is still rather rough, but this CFC will allow you to connect to your iSeries, retrieve a filtered list of spool files, and download a spool file into ASCII or PDF format.  This is really not 'production ready' code,  but it does function in its limited capacity right now.  I am releasing this to solicit opinions or additions to this, and maybe even find other sections of the iSeries toolkit that someone else has addressed.  It would be cool to create a Riaforge project that has a rollup of CFC's that can interact with the AS400 to do anything! *Note: You  need to install the JTOpen classes into the coldfusion classpath and restart before this component will work.

Anyway, you can download the wrksplf.cfc file and check it out. Don't try and drop it into a production environment, just look and see if you can learn anything from it, and if you have something to contribute either email me at justice@cfcode.net, or comment here!

SQL Fun - Let the DB do the work

I'm a firm believer that you should always let your database server return data as pure and ready for display as possible. While coldfusion *can* take your entire dataset and break it into pages, and Query of Queries has some decent functionality to mix things up, I find it is orders of magnitude faster to leave that work to your database server. With the following snippets your mileage may vary, as these are primarily done in MS SQL of some variety, but at least this may show you some tricks you didn't know!

2 Comments

few AS400 query nuggets

I have not posted anything iSeries related in a while, so I thought I would toss up some of the little functions I have gathered from different places. If you dont work with an AS400, then dont click 'read more' and move along =)

1 Comment

Multi-Step form in Model-Glue with Services

While I don't make any claims at being a model-glue expert, I did come up with a way to run my multi-step forms in model-glue. I basically use a single 'event' entry point that has several named results, and the single entry point controller runs 'makeEventBean()' against my form bean (kept in session), and then passes the bean to the service and asks 'what is my next step?' The next named step gets fired off to the named result, and the user see's the appropriate screen in the multi-step process. I am using Transfer ORM, so inside the service you will see some use of that code. Also, I am not going to paste the display files here, this is just really to blog about the gist of my methods to handle a multi-step form. There are quite a few little code chunks here, so without further ado...

CfEclipse Beta and Eclipse 3.4 issues and resolutions

I am rocking the latest CfEclipse Beta and Eclipse 3.4.  Impressions?  Fast, I love the updated SVN dialog boxes, and everything feels nice and stable.  Only problems were Tag-Insight for CfEclipse and missing line numbers.  CJ from IRc (thanks bud!) pointed me to the fixes, so I figured I would share.

To fix the missing tag-insight:  Right click your project, and select 'Add Remove CFE Nature' (no clue what it is or does, but it fixed me right up)

To fix missing line numbers:  in your workspace, find file .metadata\.plugins\org.eclipse.core.runtime\.settings\org.cfeclipse.cfml.prefs and add a line with this text:    lineNumberRuler=true

Have a great weekend all!

8 Comments