Solved

OWA_UTIL.TABLEPRINT on the web

Posted on 2000-04-20
3
930 Views
Last Modified: 2012-05-04
Can you specify 2 or more tables in the owa_util.tableprint command?  Kind of like instead of displaying 1 table on a web page you display a "JOIN" of two tables.
Any code examples would be appreciated!
0
Comment
Question by:reenie1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Expert Comment

by:davecee
ID: 2746763
Yes, just create a view of the joined tables and pass the view name to owa_util.tableprint. For example:

 create view empdept (Ename, Dname) as
(select Ename, Dname from emp, dept
 where emp.deptno = dept.deptno);

 owa_util.tableprint(ctable=>'empdept', cclauses=>'order by Ename');

 In the long run it's easier to write custom table display routines for your own tables, views, and joins since tableprint is inflexible in other ways.

 Dave
0
 

Author Comment

by:reenie1
ID: 2748141
That answer was helpfull...but being a web application we do not give the user rights to create a table or a view...is it possible to use a cursor in the OWA_UTIL.TABLEPRINT command instead of a view or table?
0
 

Accepted Solution

by:
davecee earned 50 total points
ID: 2748315
You would usually create the view as a separate one-time step when installing the application, then web users would call owa_util.tableprint on that view at runtime.

 You can't use a dynamically-created object like a cursor with tableprint because it uses the Oracle data dictionary to get the names and data types of the table/view columns.

 You can however use owa_util.cellsprint with a dynamic query, maybe you should take a look at that, although as I said earlier you may find it easier just to write custom table generation procedures yourself.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article started out as an Experts-Exchange question, which then grew into a quick tip to go along with an IOUG presentation for the Collaborate confernce and then later grew again into a full blown article with expanded functionality and legacy…
How to Create User-Defined Aggregates in Oracle Before we begin creating these things, what are user-defined aggregates?  They are a feature introduced in Oracle 9i that allows a developer to create his or her own functions like "SUM", "AVG", and…
This video shows information on the Oracle Data Dictionary, starting with the Oracle documentation, explaining the different types of Data Dictionary views available by group and permissions as well as giving examples on how to retrieve data from th…
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question