Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

pbl 115 identity handling - looks like a bug

101 views
Skip to first unread message

Sasha

unread,
Apr 24, 2009, 4:49:49 PM4/24/09
to
team sybase:

based on the hint from Terry i went to pbodb115.ini
and in [MS_SQLSERVER_SYNTAX] section found

GetIdentity='Select @@identity'
; GetIdentity='Select max(IDENTCOL) from &TableName'

in pbl 115, this setting plugs in the global identity which is wrong.

then, i surely assumed that the second GetIdentity must be active:

; GetIdentity='Select @@identity'
GetIdentity='Select max(IDENTCOL) from &TableName'


now, the pbl 115 plugs null in identity.
obviously, Select max(IDENTCOL) fails.

this looks like a critical PBL 115 bug to me,
but i do not want to start panicking yet.

i might be still missing something in pbl 115 setup.
pls advise.

thank you, sasha
PS
out of natural curiousity, i brought up my old PBL 90 application,
and found out that pbl 90 disregards which GetIdentity is active
in pbodb90.ini.

somehow, PBL 90 always plugs in the max(IDENTCOL) of the table
which gives the correct identity value.

funny enough, this looks like a PBL 90 "positive" bug, so to speak.


Arnd Schmidt

unread,
Apr 24, 2009, 5:57:07 PM4/24/09
to
Make sure you are editing the right pbodbxxx.ini ;-) Maybe you got 2 of the pbodb90.ini..

For SQL Server we use:

GetIdentity='Select IDENT_CURRENT (''&TableName'')'

You can search the web for "@@indentity SCOPE_IDENTITY IDENT_CURRENT" and will get
a detailed description of the differences at the Microsoft Transact-SQL Help.

hth

Arnd

Sasha

unread,
Apr 24, 2009, 6:21:58 PM4/24/09
to
yes, this syntax worked.

thank you Arnd.
you seem to be not part of the team sybase, so
with your permission i will

suggest to team sybase to make the fix in the pbodb115.ini file:


in the [MS_SQLSERVER_SYNTAX] section
replace

GetIdentity='Select max(IDENTCOL) from &TableName'

(sybase syntax)

with

GetIdentity='Select IDENT_CURRENT (''&TableName'')'

also, make the above the default as opposed to
GetIdentity='Select @@identity'

regards, sasha


"Arnd Schmidt" <arnd.s...@gmx.de> wrote in message
news:15d4v4h2m4fe93f2l...@4ax.com...

Chris Keating [Sybase iAnywhere]

unread,
Apr 24, 2009, 8:13:42 PM4/24/09
to
Please note that TeamSybase are end-users and not Sybase. If you want to
report a bug, please communicate with Sybase (case-express.sybase.com or
by contacting your local support center).

-chris

0 new messages