IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Question in Null Indicator/Rowid/VSAM In DB2/Buffer Pools


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
RamsIBM

New User


Joined: 08 Jan 2007
Posts: 53
Location: Chennai

PostPosted: Tue Mar 11, 2008 5:17 pm
Reply with quote

Hi Friends,

I got following question while brushing up my DB2 knowledge

1)Null Indicator
0 – for successful execution
-1 – Null deducted
what is -2 means??

2)Do we have anything like Rowid concept in DB2 which is in oracle??

3)The only place of VSAM KSDS used in DB2?

4)How many buffer pools are available in db2? Size? And usage of buffer pools?

5)Move -1 to IND-HIREDATE
EXEC SQL UPDATE EMPLOYEE SET HIREDATE=:HV-HIREDATE:IND-HIREDATE
WHERE EMPNO=:HV-EMPNO
END-EXEC.

Will indicator variable assign null value to the table even if Host Varible got some value?
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Tue Mar 11, 2008 5:58 pm
Reply with quote

1. Null Indicator
If the null indicator value is negative, the fetched value is null and the host variable should not be used.

By the way, if it is -2
If the database configuration parameter dft_sqlmathwarn is set to 'YES', the null-indicator variable value may be -2. This value indicates a null that was either caused by evaluating an expression with an arithmetic error, or by an overflow while attempting to convert the numeric result value to the host variable.
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Tue Mar 11, 2008 6:01 pm
Reply with quote

5. Question
When processing INSERT or UPDATE statements, the database manager checks the null-indicator variable, if one exists. If the indicator variable is negative, the database manager sets the target column value to null, if nulls are allowed.

If the null-indicator variable is zero or positive, the database manager uses the value of the associated host variable
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Tue Mar 11, 2008 6:07 pm
Reply with quote

3)The only place of VSAM KSDS used in DB2?

This may be one reason. But What about the great functionalities of RDBMS and its advantages(includes XML support, Unicode, multi-platform support & programmimg lanuages, etc)?
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Tue Mar 11, 2008 6:09 pm
Reply with quote

2)Do we have anything like Rowid concept in DB2 which is in oracle??

Yes, it is if I understand your question correctly.

Please visit this link for more information.
publib.boulder.ibm.com/infocenter/dzichelp/v2r2/index.jsp?topic=/com.ibm.db2.doc.sqlref/xf7c63.htm
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Tue Mar 11, 2008 6:24 pm
Reply with quote

4)How many buffer pools are available in db2? Size? And usage of buffer pools?

I got these info from IBM library.

Buffer pools are areas of virtual storage that temporarily store pages of table spaces or indexes. When an application program accesses a row of a table, DB2 places the page that contains that row in a buffer.

Depends on how many Buffer pools you would like to define to the system. DB2 allows you to use up to 50 buffer pools that contain 4-KB buffers and up to 10 buffer pools each for 8-KB, 16-KB, and 32-KB buffers.

The minimum buffer pool storage that DB2 allocates
4KB 2000 pages
8KB 1000 pages
16KB 500 pages
32KB 250 pages

Types :

At any moment, a database buffer pool can have in-use, updated, and available pages.

Please visit these links for clear information.
www.ibm.com/developerworks/db2/library/techarticle/0212wieser/0212wieser.html
publib.boulder.ibm.com/infocenter/dzichelp/v2r2/index.jsp?topic=/com.ibm.db29.doc.perf/db2z_tunedbbufferpools.htm
publib.boulder.ibm.com/infocenter/dzichelp/v2r2/index.jsp?topic=/com.ibm.db29.doc.perf/db2z_bufferpoolpagetypes.htm
Back to top
View user's profile Send private message
RamsIBM

New User


Joined: 08 Jan 2007
Posts: 53
Location: Chennai

PostPosted: Wed Mar 12, 2008 11:06 am
Reply with quote

Hi Gnanas,

Good Day.

Thank you for your reply.

But am still not clear in 3rd answer.

Usually DB2 tables are stored as LDS(VSAM).

Can you tell me in which place of DB2 uses KSDS(VSAM)??
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Wed Mar 12, 2008 12:13 pm
Reply with quote

if I remember correctly the BSDS is a vsam/ksds
but that info can be checked by running an idcams listcat
Back to top
View user's profile Send private message
Gnanas N

Active Member


Joined: 06 Sep 2007
Posts: 792
Location: Chennai, India

PostPosted: Wed Mar 12, 2008 2:47 pm
Reply with quote

In DB2, a table space can consist of a number of VSAM data sets. Data sets are VSAM linear data sets (LDSs).

DB2 writes each log record to a disk data set called the active log. Each active log data set is a VSAM LDS. Also, DB2 supports striped active log data sets.
Yes, Enrico, you are correct. icon_biggrin.gif
The bootstrap data set (BSDS) is a VSAM key-sequenced data set (KSDS) that contains information critical to DB2.
Back to top
View user's profile Send private message
RamsIBM

New User


Joined: 08 Jan 2007
Posts: 53
Location: Chennai

PostPosted: Thu Mar 13, 2008 11:52 am
Reply with quote

Thanks Guys....
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts Merge two VSAM KSDS files into third ... JCL & VSAM 6
No new posts Null values are considered in Total c... DFSORT/ICETOOL 6
No new posts Question for file manager IBM Tools 7
No new posts CVDA value for RRDS VSAM dataset. CICS 2
Search our Forums:

Back to Top