Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: How to do this as a singleton select?
rgaffuri_at_cox.net (Ryan Gaffuri) wrote in
news:1efdad5b.0301100357.465f2c38_at_posting.google.com and I quote:
> The modeller is using a supertype, subtype design. I have a supertype
> table. This table has records that tell me which 'subtype' tables to
> use based on certain criteria.
That is fine.
>
> My subtype tables are not always of the same form.
>
That is *not* fine...
> Didnt design it. Just have to use it. Plus, since the project is in
> RAD, the data isnt always accurate. So I may get told to use this
> subtype table, but it may be of the wrong structure(different columns
> that what I need) causing my dynamic cursor to throw an exception. So
> I have to filter it out.
Use a *getter* interface? Package, defining functions that return a refcursor. Populate an in-memory table with the results as you check/verify/build them, then use
select ... TABLE(CAST (... as user_type>))
to generate the return ref cursor.
Works for me.
>
> Gotta be extra careful. Our GUI is done in .net. I dont know .net and
> the .net guys dont know the database.
>
J2EE here. Same problem. Complex functionality, complex design. Gotta shield the Java people fromt he complexities of SQL. Just use "getters". They understand the term and it actually *is* very fast.
-- Cheers Nuno Souto nsouto_at_optusnet.com.au.nospamReceived on Fri Jan 10 2003 - 06:24:48 CST