When connecting to Sybase ASE there are connection parameters 'Host' (the machine name of the client) and 'AppName' (the name of the client application). Then while the application is connected, the entry in the sysprocesses table shows those values.

I would like to do the same thing for SQL Anywhere if it is possible. If it is possible, would the values appear in the same columns of sysprocesses?

My application is written in PowerBuilder.

asked 21 Oct '11, 14:44

Roland%20Smith's gravatar image

Roland Smith
91448
accept rate: 0%


SQLAnywhere doesn't have a sysprocesses but the application info you are looking for can be acquired via a different mechanism. See http://dcx.sybase.com/index.html#1201/en/dbadmin/appinfo-connection-conparm.html*d5e18109.

permanent link

answered 21 Oct '11, 14:55

John%20Smirnios's gravatar image

John Smirnios
11.9k396165
accept rate: 37%

I'm hoping to be able to show a list of connected users when the database is running as a server (as opposed to local single user).

(21 Oct '11, 15:12) Roland Smith
Replies hidden

See sa_conn_info, sa_conn_list and connection_property in the documentation. For example, you might do "select userid, connection_property( 'appinfo', Number ) from sa_conn_info()"

(21 Oct '11, 15:23) John Smirnios

The HOST parameter may be picked up by the data provider. For the Application Name, you can specify this using the AppInfo connection parameter:

AppInfo Connection Parameter

APPINFO='MyApplication'

The value can be viewed as part of:

SELECT CONNECTION_PROPERTY('AppInfo'[,connection_id]);
permanent link

answered 21 Oct '11, 15:18

Tyson%20Lewis's gravatar image

Tyson Lewis
2.2k1641
accept rate: 22%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×44

question asked: 21 Oct '11, 14:44

question was seen: 2,091 times

last updated: 21 Oct '11, 15:23