Re: WebDB: form based on view creation problem

From: Steve Jennings <spj95_at_hotmail.com>
Date: Mon, 17 Apr 2000 22:43:09 GMT
Message-ID: <8dg41p$orv$1_at_nnrp1.deja.com>


I succeeded in getting the form to work, but it wasn't through either of those methods.

I didn't want to alter the code or alter the privileges as I will most likely be deploying the site and components quite often and don't want to have to implement the changes each time.

So my (rather inelegant) solution was to create a view in the component schema which selected all the fields from the original view.

[Quoted] On a slightly different note - is there any way of debugging the WebDB code?

Thanks,

Steve

In article <uW2K4.89305$l35.182530_at_afrodite.telenet-ops.be>,   "Leo Van Nieuwenhuyse" <leo.van.nieuwenhuyse_at_pandora.be> wrote:
> Wich version of webdb?
> In 2.2(I presume in other versions too) there's a bug in the package
> wwv_utlbuild of the webdb schema:
> In the function validate_table_names you'll find the next code:
>
> elsif l_type_name = 'ADFORM' then
> l_owner := wwv_utlattr.get_attribute_value_byname('P_OWNER');
> l_name :=
> upper(wwv_utlattr.get_attribute_value_byname('P_REPORT_TABLES'));
> if l_name is null or l_name = wwv_global.NULLVALUE then
>
wwv_stderr.stack_error('WWV_UTLBUILD.VALIDATE_TABLE_NAMES',
> 13021, l_obj_type);
> wwv_builder.show_error('WWV_UTLBUILD.VALIDATE_TABLE_NAMES:
Table
> Name cannot
> be NULL');
> return false;
> end if;
>
> for c in (select owner || '.' || object_name name
> from all_objects
> where object_type in ('TABLE','VIEW')
> and owner = l_owner
> union
> select table_schema || '.' || table_name name
> from all_tab_privs
> where grantee in (l_owner, 'PUBLIC') and privilege =
> 'SELECT')
> loop
>
> The select is done form ALL_TAB_PRIVS, wich means that you will never
see
> objects your schema granted to another schema or role! Why? Webdb is
the
> owner of the procedure and since webdb has not been granted access
> all_tab_privs will not show the table you want.
>
> I solved this by replacing in the code the last select by:
>
> select owner || '.' || table_name name
> from dba_tab_privs
> where grantee in (l_owner, 'PUBLIC') and privilege =
> 'SELECT').
>
> If you do not want to change in webdb's code you can do the following:
>
> 1) Grant the rights on your table to PUBLIC
> 2) Create the module, webdb will see the table now
> 3) Revoke the rights on your table from PUBLIC
> 4) Put the right grants to the right roles or schemas.
>
> Let me know if you succeeded.
> <spj95_at_hotmail.com> schreef in berichtnieuws
8d86ij$efq$1_at_nnrp1.deja.com...
> >
> >
> > I am trying to create a form based on a view but am getting the
error
> > message:
> >
> > "WWV-13020 This Table does not exist or you do not
> > have the required privileges.
> >
> > WWV_UTLBUILD.VALIDATE_TABLE_NAMES"
> >

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Tue Apr 18 2000 - 00:43:09 CEST

Original text of this message