Raptor SQL Formatter Issue…

It looks like there are some outstanding issues with the Raptor SQL formatter. It doesn’t appear to work at all when editing a package, but it will work for a procedure or an SQL statement. When it does work it appears to have some odd ideas about how PL/SQL variables should be defined. This example shows one case:

-- Before
CREATE OR REPLACE PROCEDURE dummy_proc AS
l_dummy_1 dual.dummy%type;
l_dummy_2 dual.dummy%type;
BEGIN
l_dummy_1 := 'x';
DBMS_OUTPUT.PUT_LINE('l_dummy_1=' || l_dummy_1);
l_dummy_2 := 'x';
DBMS_OUTPUT.PUT_LINE('l_dummy_2=' || l_dummy_2);
END;

-- After
CREATE OR REPLACE PROCEDURE dummy_proc AS l_dummy_1 dual.dummy % type;
l_dummy_2 dual.dummy % type;
BEGIN
l_dummy_1 := 'x';
DBMS_OUTPUT.PUT_LINE('l_dummy_1=' || l_dummy_1);
l_dummy_2 := 'x';
DBMS_OUTPUT.PUT_LINE('l_dummy_2=' || l_dummy_2);
END;

It seems to be a little confused by the declaration section of the procedure. I’ve posted this on the support forum. I hope this gets fixed before the production release.

In addition to this, the SQL formatter is a little lacking in configuration options.

Cheers

Tim…

Raptor. It does what it says on the tin…

I guess everyone knows by now that Raptor has arrived now. I downloaded it and had a little play and here are my first impressions:

  • It takes an age to start up. No doubt this is due to it being based on the JDeveloper framework. The words “Java” and “Fast” are rarely used in the same sentence where GUI applications are concerned.
  • Once loaded, the application is quite quick and responsive.
  • The look and feel is clean and simple, not dissimilar to PL/SQL Developer. Not at all like the “junk-yard” that is TOAD.
  • There are a few nice touches. When dealing with large numbers of objects, expanding the navigator does not list all of them. Instead, it lists the first few and gives you the option for more. This is much better than waiting around for ages, especially when you’ve expanded the wrong node 🙂
  • I’m not totally sure the editor window deals with fonts correctly. On my installation 12pt looks really chunky, but 10pt requires a magnifying glass to read. I usually use 8pt for my regular text editor, so something is a little fishy here.
  • It has all the things you would expect for a PL/SQL development tool, like syntax highlighting, debugger, PL/SQL beautifier etc. In addition it has a reporting tab that allows you to produce predefined and user defined reports. This is a nice touch for those people that have an endless array of custom scripts.

My initial impression is very positive, although it will be the New Year before I get to use the product in anger. I’m glad Oracle have resisted the temptation to build an “all things to all people” product. I find most IDEs annoying because of the shear volume of junk included. If Oracle keep it simple and keep it free this is going to be a bigtime winner.

I see no reason to pay for a product like PL/SQL Developer when you can use Raptor for free. TOAD may be a different matter though. Personally, I prefer Raptor’s clean interface to the clutter of TOAD, but if you are somebody that uses all the rubbish included in TOAD, then Raptor is probably not for you.

Over the last few months I’ve seen myself slip into a very negative frame of mind regarding Oracle products. Perhaps Raptor is a turning point. Keep up the good work!

Cheers

Tim…

Windows…

I have one XP machine that I use for remote access to work. I need to use Windows on it as the VPN software I have to use is Windows only. Yesterday the Windows installation died and it doesn’t want to be repaired. The disk is fine, it’s just the crappy OS that is moaning. How I loath Microsoft products sometimes.

I’ve managed to install the VPN software on a Windows virtual machine on my CentOS box, the previous version wouldn’t allow this for some reason, so I have remote access again, but no need for a dedicated Windows machine. All is well with the world!

Cheers

Tim…

King Kong and the last of the Christmas parties…

I went to to see King Kong on Friday night. Considering it was 3 hours long, it went by in a flash. I was a little worried I’d get bored senseless, like I was during LOTR – The Two Towers, but it wasn’t a problem. In my opinion, it’s well worth a visit to the big screen.

I had a couple of Christmas events this weekend. First was the Karate Club Christmas party on Saturday night. Lots of food and quite a bit of dancing. It was a great laugh and I got home at about 03:00, so I was a bit knackered for the second event, which was Sunday lunch with some friends I won’t get to see at Christmas. That marks the end of the planned Christmas parties for this year, so it’s back normal eating in an attempt to reduce my current girth 🙂

Cheers

Tim…

PL/SQL Beautifier…

I think Oracle should include an SQL and PL/SQL beautifier (formatter) in the next version of the engine. I know there are lots of third party tools to do this, but it would be nice to produce readable output from queries against the v$ views, rather than having to cut & paste blocks of SQL output into a 3rd party tool to format it.

Why put it in the engine?

Remember the days when everyone and their dog had scripts to pull out object definintions from the database by querying the data dictionary? It became a real pain keeping them up to date, so Oracle released the DBMS_METADATA package so each version of the engine had the correct method for returning the object definintions.

In the same way, each version of the engine comes with new and modified syntax, which will often require modifications to beautifier code. Put it on the database, and let external tools access it. Added to that, it would solve my problem that prompted this post.

I’m sure they already have the code in Raptor. If they don’t want to write it in PL/SQL, they could always wrap up the Java code as a Java Stored procedure and make it available from the engine.

Cheers

Tim…

Christmas Parties and Parking…

Friday Night – I went to a Christmas party with my Yoga mates. One of the guys got his car clamped and had to pay £94 to get the clamp removed.

Saturday Night – Work Christmas party. I got my car locked in a car park overnight. I didn’t get a parking ticket, but it cost me £22 in taxi fares.

The moral of this story is, Christmas is not designed for sober people 🙂

Cheers

Tim…

PS. Two more Christmas parties next weekend…