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.

SQLfromSyntax Not finding key data

2 posts in DataWindow Last posting was on 2008-04-09 18:08:41.0Z
Kevin Furey Posted on 2008-04-07 19:51:38.0Z
Reply-To: "Kevin Furey" <fureykp@yahoo.com>
From: "Kevin Furey" <fureykp@yahoo.com>
Newsgroups: sybase.public.powerbuilder.datawindow
Subject: SQLfromSyntax Not finding key data
Lines: 141
Organization: SAIC
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="----=_NextPart_000_0006_01C898BE.CE7680A0"
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <47fa7b4a$1@forums-1-dub>
Date: 7 Apr 2008 12:51:38 -0700
X-Trace: forums-1-dub 1207597898 10.22.241.152 (7 Apr 2008 12:51:38 -0700)
X-Original-Trace: 7 Apr 2008 12:51:38 -0700, vip152.sybase.com
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.datawindow:86616
Article PK: 415876

using Powerbuilder 10.5.2 7611 EA Server 6.0.2.22 the database is Oracle 9i using JDBC connection cache.
 
The problem is that using syntax from sql with a db connection that does not own the table being selected from the key information for the columns is not being gathered by SyntaxFromSQL. I specify the owner name in the select.
 
Using the id that does not own the tables generates ...
table(column=(type=char(64) updatewhereclause=yes name=section_index dbname="SECTION_INDEX"  )
column=(type=char(64) updatewhereclause=yes name=key_index dbname="KEY_INDEX"  )
column=(type=char(256) updatewhereclause=yes name=data_value dbname="DATA_VALUE"  )
 retrieve="select * from ADS_ADMIN.T_APP_PREFERENCES"
 
Using an id that does own the tables generates the following...

table(column=(type=char(64) key=yes update=yes updatewhereclause=yes name=section_index dbname="SECTION_INDEX" )

 column=(type=char(64) key=yes update=yes updatewhereclause=yes name=key_index dbname="KEY_INDEX" )

column=(type=char(256) update=yes updatewhereclause=yes name=data_value dbname="DATA_VALUE" )

retrieve="select * from ADS_ADMIN.T_APP_PREFERENCES"

update="T_APP_PREFERENCES" updatewhere=1 updatekeyinplace=no )

The key=yes values are found so the datawindow generated is updateable.

I can modify the update and updatewhere where and all that but, I won't know the key data for the columns because this is all dynamic. It could be any table. I can't use the table owner id in Prod. This seems like a permissions issue for the non owner id. But, what permissions do I have to grant? What tables? A system table? I granted all to the pb extended attribute tables to no avail. I can connect in the database painter using the non owner id and modify data in the same table successfully.

Is this a known bug?

This works with either id on the same database in EA Server 4.1 and Powerbuilder 8.03.

Thanks,

Kevin


Kevin Furey Posted on 2008-04-09 18:08:41.0Z
Reply-To: "Kevin Furey" <fureykp@yahoo.com>
From: "Kevin Furey" <fureykp@yahoo.com>
Newsgroups: sybase.public.powerbuilder.datawindow
References: <47fa7b4a$1@forums-1-dub>
Subject: Re: SQLfromSyntax Not finding key data
Lines: 54
Organization: SAIC
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <47fd0629$1@forums-1-dub>
Date: 9 Apr 2008 11:08:41 -0700
X-Trace: forums-1-dub 1207764521 10.22.241.152 (9 Apr 2008 11:08:41 -0700)
X-Original-Trace: 9 Apr 2008 11:08:41 -0700, vip152.sybase.com
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.datawindow:86621
Article PK: 415881

The key information for the select is generated correctly using the non
ownwer id if I use a JCM_Oracle_Unicode driver based datasource as the
transaction to create the syntax.

Is there a setting on the JDBC driver , a property I could add to make this
work or is it a bug?

Thanks again,

Kevin


"Kevin Furey" <fureykp@yahoo.com> wrote in message
news:47fa7b4a$1@forums-1-dub...
using Powerbuilder 10.5.2 7611 EA Server 6.0.2.22 the database is Oracle 9i
using JDBC connection cache.

The problem is that using syntax from sql with a db connection that does not
own the table being selected from the key information for the columns is not
being gathered by SyntaxFromSQL. I specify the owner name in the select.

Using the id that does not own the tables generates ...
table(column=(type=char(64) updatewhereclause=yes name=section_index
dbname="SECTION_INDEX" )
column=(type=char(64) updatewhereclause=yes name=key_index
dbname="KEY_INDEX" )
column=(type=char(256) updatewhereclause=yes name=data_value
dbname="DATA_VALUE" )
retrieve="select * from ADS_ADMIN.T_APP_PREFERENCES"

Using an id that does own the tables generates the following...
table(column=(type=char(64) key=yes update=yes updatewhereclause=yes
name=section_index dbname="SECTION_INDEX" )
column=(type=char(64) key=yes update=yes updatewhereclause=yes
name=key_index dbname="KEY_INDEX" )
column=(type=char(256) update=yes updatewhereclause=yes name=data_value
dbname="DATA_VALUE" )
retrieve="select * from ADS_ADMIN.T_APP_PREFERENCES"
update="T_APP_PREFERENCES" updatewhere=1 updatekeyinplace=no )
The key=yes values are found so the datawindow generated is updateable.
I can modify the update and updatewhere where and all that but, I won't know
the key data for the columns because this is all dynamic. It could be any
table. I can't use the table owner id in Prod. This seems like a permissions
issue for the non owner id. But, what permissions do I have to grant? What
tables? A system table? I granted all to the pb extended attribute tables to
no avail. I can connect in the database painter using the non owner id and
modify data in the same table successfully.
Is this a known bug?
This works with either id on the same database in EA Server 4.1 and
Powerbuilder 8.03.
Thanks,
Kevin