Friday, September 27, 2013

Product Suggestion: More ISQL SET Option Commands

ISQL already HAS most of what I was going to suggest: ISQL commands to change option settings on the fly, as part of a batch of commands being processed by ISQL.

Did you know that?


Here's an example:

SET OPTION TRUNCATION_LENGTH = 70;
SELECT PROPERTY ( 'RememberLastStatement' );
SET OPTION TRUNCATION_LENGTH = 50;
SELECT PROPERTY ( 'RememberLastStatement' );
SET OPTION TRUNCATION_LENGTH = 30;
SELECT PROPERTY ( 'RememberLastStatement' );

PROPERTY('RememberLastStatement')                                      
---------------------------------------------------------------------- 
Yes                                                                    
(1 rows)


PROPERTY('RememberLastStatement')                  
-------------------------------------------------- 
Yes                                                
(1 rows)


PROPERTY('RememberLastStatemen 
------------------------------ 
Yes                            
(1 rows)

There's one option missing, however; there is no SET OPTION command to dynamically choose Tools - Options - SQL Anywhere - Results - Style - Text, you have to use the GUI:



Maybe a SET OPTION statement isn't appropriate here, maybe a dbisql command line option is better... it doesn't matter... what matters is the ability to change the option in a batch file without having to clickety-clack through the GUI whenever one or the other styles is more appropriate.


No comments: