|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
JDBC query formatting
Is it possible to do the following with JDBC and oracle db
For example, I create the following sql query using jdbc Select department_id, employee_id, salary from emp; I'm able to display ther results on a jsp page in tabular format from the result set. However, I would like to format the result as follows. department_id 1 Employee1 598.00 Employee2 100.00 department_id 1 total 698.00 department_id 2 Employee3 100.00 Employee4 200.00 department_id 2 total 300.00 Report Total 998.00 Is it possible to do this using JDBC, sql and dislpaying on jsp page without using a report writing tool |
|
#2
|
|||
|
|||
|
Not a problem with either JDBC or SQL. You will have to perform formatting functions within your JSP. One way is to break the queries down into two...select department then employees in another query and nesting tables in JSP.
|
|
#3
|
|||
|
|||
|
That's the solution that I started working on. Thanks for the confirmation!!
![]() |
![]() |
| Viewing: Dev Shed Forums > Databases > Oracle Development > JDBC query formatting |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|