If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > reports in db2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-27-04, 02:03
treddy123 treddy123 is offline
Registered User
 
Join Date: Jan 2004
Posts: 14
reports in db2

Hello All:
I am new to DB2, but have ample exp. in oracle. Now I have to write sql statements to generate reports similar to sqlplus in oracle.

in oracle we have so many options to format a report.
like
col name_of_the_field format a40 justify l (to display data in the leftside of the column)
set pagesize 100 (to set the no of lines in each page )
set linesize 100 (each linesize 100)

so can someone give me pointer to look for the formating syntax in db2.

The report generated by DB2 and Oracle has to similar.
Reply With Quote
  #2 (permalink)  
Old 01-27-04, 05:57
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
DB2 does not have a built-in report writer like Oracle Reports (or what ever it is called). But there are many 3rd party programs tht do this. Keep in mind that DB2 is about half the price as Oracle in many configuratons.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
  #3 (permalink)  
Old 01-27-04, 07:37
hanyheggy hanyheggy is offline
Registered User
 
Join Date: Jan 2004
Location: Egypt
Posts: 61
Re: reports in db2

hi,

we are using MicroSoft Crystal Report for generating reports from DB2, it is powerfull , give simliar capablites to sql reports
__________________
hany heggy,
IBM certified Professional, AIX system support
www.melodyhits.tv
Reply With Quote
  #4 (permalink)  
Old 01-27-04, 08:11
treddy123 treddy123 is offline
Registered User
 
Join Date: Jan 2004
Posts: 14
Re: reports in db2

hi,

I have to do the reports with one sql statement, so formatting of the fields to be displayed and also reight or left align can also be defined in oracle. I want to know if we have the features in DB2.
Reply With Quote
  #5 (permalink)  
Old 01-27-04, 09:08
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
No! DB2 does not have a built-in report writer. I bleive that the Oracle Report Writer is a seperate piece of code, whether it is free or costs extra, I don't know.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390

Last edited by Marcus_A; 01-27-04 at 09:58.
Reply With Quote
  #6 (permalink)  
Old 01-27-04, 09:41
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Re: reports in db2

Quote:
Originally posted by treddy123
Hello All:
I am new to DB2, but have ample exp. in oracle. Now I have to write sql statements to generate reports similar to sqlplus in oracle.

in oracle we have so many options to format a report.
like
col name_of_the_field format a40 justify l (to display data in the leftside of the column)
set pagesize 100 (to set the no of lines in each page )
set linesize 100 (each linesize 100)

so can someone give me pointer to look for the formating syntax in db2.

The report generated by DB2 and Oracle has to similar.
You are out of luck. DB2 command line processor does not have formatting capabilities of SQLplus. The best you can do is to turn off headings and various messages to output bare data and then format them using OS tools (if you're on *nix).

Alternatively, you can use 3d party report software (e.g. Crystal Reports) or even MS Excel to format your output.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On