Hi Folks

OK. I ran a series of tests:

o If I want to set the schema I can do that in the call to
Rose::DB->register_db, just as I can with driver, database, etc, although I have
not yet found a Rose doc indicating this was possible

o list_tables doesn't need a schema. All of:
        - undef
        - '%'
        - uc $self -> username
produce the same ouput - correct - in the call to $dbh -> table_info. This
surprised me. I thought it had to be the last form (explanation below). For
consistency with the DBI docs, I'll use $self -> schema in the call to
list_tables and at the same time will delete sub schema from Oracle.pm, so it
Just Works. Using an empty string does not work

o I have another program which calls:
        - table_info
        - column_info
        - primary_key_info
        - foreign_key_info
(don't we all?) and it turns out the culprit to all this is primary_key_info. In
/its/ schema parameter, I have to have uc $user to get any output. That's why I
set schema to uc $user throughout this program, and hence why I transferred the
info to Oracle.pm. Keep that in mind...

o So why don't I use '%'? My assumption is that under (currently unknown)
circumstances it can return too much information. That is, by using $self ->
schema and by letting you set the schema in the call to register_db, you'll be
getting back info on precisely the schema you specified (i.e. wanted). If you
want table info for another schema (i.e. user), just create another entry in the
registry via register_db, and use that

Time passes...

Yes, I've now run another test for 2 users as just described, and it does what I
expect, by listing tables per schema (after fixing my attempt at sub build_dsn).

--
Ron Savage
[EMAIL PROTECTED]
http://savage.net.au/index.html




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to