Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

using group by and fetching multiple records

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
i_suman

New User


Joined: 01 Mar 2005
Posts: 20

PostPosted: Fri Oct 03, 2008 6:36 am    Post subject: using group by and fetching multiple records
Reply with quote

I have one requirement..
For the RI_NUM variable taking from file, I need to select the count of incidents from 1100 table for each of the 4 groups where the DEL-TS is null. Use the 1700 table to tell which incdt_type_cd values belong to the groups.
1700 has following columns
Incdt_type_cd
Incdt_grp_cd

4groups are A1, A2, A3, A4.

can some one help me with the sql query that satisfies this requirement.
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Fri Oct 03, 2008 6:47 am    Post subject:
Reply with quote

Hello,

You need to present more complete info.

If you post the needed column definitions from the tables, some sample data from the 2 tables, and the "output" you want, someone will be better able to offer suggestions. This does not need to be a lot of data, just enough to adequately show what you need.

Keep in mind that the most inportant part of getting help from the forum is doing a thorough job of explaining the requirement.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts Unable to create multiple files using... mbattu COBOL Programming 3 Fri May 05, 2017 5:35 pm
No new posts Group Data based on a key Arun Raj DFSORT/ICETOOL 7 Thu Apr 27, 2017 11:29 pm
This topic is locked: you cannot edit posts or make replies. SDSF multiple spool datasets extracte... PJAlarcon CLIST & REXX 1 Fri Apr 21, 2017 10:50 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us