The forum will experience an outage sometime between February 10 at 7:00pm EST and February 12 at 11:59 EST for installation of security updates. The actual time and duration of the outage are unknown but attempts will be made to minimize the downtime. We apologize for any inconvenience.

What's the real difference between this 2 connection parameter?

asked 10 Nov '09, 11:00

Zote's gravatar image

accept rate: 43%

edited 15 Nov '09, 10:54

Breck%20Carter's gravatar image

Breck Carter

The SQL Anywhere engine initializes APP (or AppInfo) to a long string full of interesting and sometimes helpful information, whereas CON (or ConnectionName) starts out empty.

When you give values for APP and CON in your connection string, your APP value gets appended to the initial string, whereas your CON becomes the entire new value:

"%SQLANY11%\bin32\" -c "ENG=ddd11;DBN=ddd11;UID=dba;PWD=sql;

       CONNECTION_PROPERTY ( 'Name' );

'IP=;HOST=PAVILION2;OSUSER=bcarter;OS=''Windows XP 
Build 2600 Service Pack 3'';EXE=''C:\\Program Files\\SQL Anywhere 

Personally, I haven't used APP much but I know people who do. However, I use CON all the time so I can tell connections apart, especially when every connection is using the same user id... not just connection pools, but a lot of classic embedded and other applications.

SQL Anywhere utilities, events and CREATE SERVICE web services set CON values; I don't have a complete list handy. Some of them are meaningful, some of them not so much: SQL_DBC_c657ef0

FWIW, the Foxhound database monitor does not display APP, either for its own connection or for any other connection, but it always shows CON... APP is on the future feature list but only as a "possible"... it takes up a lot of bandwidth for little (IMO) value, especially when you are monitoring 1000 connections. CON, on the other hand, can save your sanity.

BTW, that comment about bandwidth ONLY applies to Foxhound, not normal usage. And I think the built-in SQL Anywhere Monitor is the same but I would have to look.

Other than that, they might be the same: input parameters provided by the client side, available to application code via SELECT INTO, and to stored procedure logic via SELECT INTO or just simple function references: SET @variable = CONNECTION_PROPERTY ( 'AppInfo' );

permanent link

answered 10 Nov '09, 14:07

Breck%20Carter's gravatar image

Breck Carter
accept rate: 21%

Your answer
toggle preview

Follow this question

By Email:

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



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "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:


question asked: 10 Nov '09, 11:00

question was seen: 1,503 times

last updated: 15 Nov '09, 10:54