Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Why cant we use Union in embedded SQL

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

New User


Joined: 31 Mar 2004
Posts: 4

PostPosted: Tue May 30, 2006 11:59 am    Post subject: Why cant we use Union in embedded SQL
Reply with quote

(1) which DB2 utility program used to make full image copy and incremental image copy?

(2) why cant we use Union in embedded SQL?

Thanks mohideen.
Back to top
View user's profile Send private message

callkris_cit

New User


Joined: 22 Apr 2006
Posts: 44

PostPosted: Wed May 31, 2006 3:19 pm    Post subject: Re: Why cant we use Union in embedded SQL
Reply with quote

(1) which DB2 utility program used to make full image copy and incremental image copy?

DSNUTILB utility program is used to take a Image copy and Incremental copy.

(2) why cant we use Union in embedded SQL?

We can use Union in embedded SQL. But you should create a Cursor for Select statement.
Back to top
View user's profile Send private message
mahsug

New User


Joined: 01 Jul 2003
Posts: 15
Location: Phoenix , AZ

PostPosted: Fri Jun 02, 2006 5:08 pm    Post subject: Why cant we use Union in Embedder Sql
Reply with quote

Hi ,

I have a small correction to what Krsi said , DSNUTILB is a program , which would be made use for most of the Db2 batch programs , its only the input / control card statements would make difference for the utility.

For the above query , the input program would DSNUTILB , and the Db2 utility is COPY
and the statement for full image copy would be like

COPY TABLESPACE <DBNAME >.<TSNAME> FULL YES

and the statement for Incremental image copy would be like

COPY TABLESPACE <DBNAME >.<TSNAME> FULL NO

Referring to the query no 2 regarding usage of union in embedded SQL ,.
we can certainly use the union withCURSORS , but the overhead on the memory will be too high (Assuming , your result sets are very huge ), which would degrade the application performance.

Let me know , if more questions

Mahesh
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 cobol embedded sql MS_Developer COBOL Programming 7 Fri Oct 14, 2016 2:39 pm
No new posts Null Indicator value -2 means in Embe... deepak_shrivastava DB2 2 Wed Jan 06, 2016 10:27 pm
No new posts [SQL0029] INTO clause missing from em... HABBIE DB2 2 Fri Sep 04, 2015 3:54 pm
No new posts Illegal use of keyword fetch. Token w... HABBIE DB2 2 Fri Aug 28, 2015 5:20 pm
No new posts Embedded programs / link'ed programs sivakumar.karthik CICS 5 Fri Jun 05, 2015 1:12 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us