Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

isql Output Format

4 posts in Windows NT Last posting was on 2001-05-02 18:49:13.0Z
Jorge Posted on 2001-04-30 17:33:22.0Z
From: "Jorge" <iamjas99@hotmail.com>
Subject: isql Output Format
Date: Mon, 30 Apr 2001 13:33:22 -0400
Lines: 9
X-Newsreader: Microsoft Outlook Express 4.72.3110.5
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Message-ID: <cVmWz5Z0AHA.178@forums.sybase.com>
Newsgroups: sybase.public.sqlserver.nt
NNTP-Posting-Host: hboc.com 139.177.224.128
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:857
Article PK: 1087464

Is there a way to format the output of isql running in a Command prompt? I
am piping the output to a text file and for result sets with many columns,
the output can be very jumbled looking. I am trying to get the output in a
columnar format no matter if I only want to see a few or many columns worth
of data. Or is there a better way of doing this?
Thanks in advance.
Jorge Ascunce


Doug Wittich Posted on 2001-04-30 17:57:40.0Z
Message-ID: <3AEDA794.E84F8F19@stpaul.com>
Date: Mon, 30 Apr 2001 13:57:40 -0400
From: Doug Wittich <doug.wittich@stpaul.com>
X-Mailer: Mozilla 4.76 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
Subject: Re: isql Output Format
References: <cVmWz5Z0AHA.178@forums.sybase.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.sqlserver.nt
Lines: 17
NNTP-Posting-Host: portald.stpaul.com 208.201.108.75
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:856
Article PK: 1087463

Add the -w parm to the command line, to specify the width of the output,
otherwise, it wraps at 80 bytes. I usually use -w256. This and a fixed
font when browsing should make it pretty enough for ISQL output.

doug

Jorge wrote:

> Is there a way to format the output of isql running in a Command prompt? I
> am piping the output to a text file and for result sets with many columns,
> the output can be very jumbled looking. I am trying to get the output in a
> columnar format no matter if I only want to see a few or many columns worth
> of data. Or is there a better way of doing this?
> Thanks in advance.
> Jorge Ascunce


Doug Wittich Posted on 2001-05-02 18:49:13.0Z
Message-ID: <3AF056A9.A8AC660B@stpaul.com>
Date: Wed, 02 May 2001 14:49:13 -0400
From: Doug Wittich <doug.wittich@stpaul.com>
X-Mailer: Mozilla 4.76 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
Subject: Re: isql Output Format
References: <cVmWz5Z0AHA.178@forums.sybase.com> <3AEDA794.E84F8F19@stpaul.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.sqlserver.nt
Lines: 26
NNTP-Posting-Host: portald.stpaul.com 208.201.108.75
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:832
Article PK: 1087440

This test will demonstrate it for you, if you have a way to look at the output
files without the lines wrapping.

#!/bin/ksh
isql -Usa -P -e << EOF | tee w.out
select getdate()
exec sp_who
go
EOF
isql -Usa -P -e -w450 << EOF | tee -a w.out
select getdate()
exec sp_who
go
EOF

Doug Wittich wrote:

> Add the -w parm to the command line, to specify the width of the output,
> otherwise, it wraps at 80 bytes. I usually use -w256. This and a fixed
> font when browsing should make it pretty enough for ISQL output.
>
> doug
>
> Jorge wrote:
>
> > Is there a way to format the output of isql running in a Command prompt? I
> > am piping the output to a text file and for result sets with many columns,
> > the output can be very jumbled looking. I am trying to get the output in a
> > columnar format no matter if I only want to see a few or many columns worth
> > of data. Or is there a better way of doing this?
> > Thanks in advance.
> > Jorge Ascunce


Jorge Posted on 2001-04-30 20:47:33.0Z
From: "Jorge" <iamjas99@hotmail.com>
References: <cVmWz5Z0AHA.178@forums.sybase.com> <3AEDA794.E84F8F19@stpaul.com>
Subject: Re: isql Output Format
Date: Mon, 30 Apr 2001 16:47:33 -0400
Lines: 11
X-Newsreader: Microsoft Outlook Express 4.72.3110.5
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Message-ID: <Qt6gUmb0AHA.178@forums.sybase.com>
Newsgroups: sybase.public.sqlserver.nt
NNTP-Posting-Host: hboc.com 139.177.224.128
Path: forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.sqlserver.nt:853
Article PK: 1087460

Could you provide an example? I tried several iterations of this and could
not get it to work.

Thanks.

Jorge