Learner
Learner

Reputation: 990

Query analyzer for Sybase

I'm querying Sybase database from C# code. Is there any good query analyzer to understand the exact queries being generated like the Query Analyzer for Sql Server?

Upvotes: 1

Views: 730

Answers (1)

kelley805
kelley805

Reputation: 26

You can set some Sybase variables to see the Query Plan such as the following:

set showplan  on
set statistics io on
set statistics time on
exec my_proc (my_arg1, my_arg2, ...)
go

I have put this into a shell script to pass the command line arguments. In that case these SQL lines are preceded with the following:

isql  -Uxxx   -Pyyy   <<-_EOF_

And the exec line becomes:

exec $*

And the script ends with:

go
_EOF_

Good SQL, good night.

kelley805

Upvotes: 1

Related Questions