SQLCommand.java cleanup: whitespace, a few redundancies, a regexp bug

Mostly this is abut standardizing whitespace for readability.
But I had trouble holding back, so you will also find:
   Places where I simplified the code to avoid anti-patterns like:
-- using containsKey to double the number of hash lookups,
-- needlessly avoiding the "for (type element : container)" idiom.
-- other cases of needlessly re-evaluating expressions like array element accesses, regexp match construction and execution (like "matches" followed needlessly by "find"), etc.

I think I MAY have found and fixed a known minor regexp bug -- at the least I made the code more consistent -- by replacing find with matches when looking for a prefix match with explain / explainproc.

I left lots of ugly whitespace in getQuery because I think that it would be easier to rewrite it as 2 functions 
getQuery(true) --> getInteractiveQueries [ slightly simpler for not having to deal with batch mode ]
and getQuery(false) --> getBatchQueries [ MUCH simpler ]

And there's still lots of room for improvement, but I think this is a good start.

If any of the actual logic changes seem the least bit ambitious, I'm willing to back them out for now just to get the whitespace changes in.
I think I got this wrong, actually.
I think that .matches finds one match but it has to match the whole string -- so it is not correct here where the pattern does not end with wildcards.
I think that .find can match by skipping arbitrary prefix text and ignoring trailing text.
Though, I think the details of what it can do may depend on the pattern's use of anchors and MULTILINE modifiers?
If successful, .find caches the ending position (in the string) of the matched pattern, so that the next call to .find on the same matcher object starts from there or fails if the pattern match consumed the whole string.

I'm going to back this out for now -- too ambitious.