MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

DB2 logging

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Database
View previous topic :: View next topic  
Author Message
misi01
Advanced


Joined: 02 Dec 2002
Posts: 614
Topics: 171
Location: Stockholm, Sweden

PostPosted: Mon Sep 27, 2021 7:47 am    Post subject: DB2 logging Reply with quote

Some background. I'm working at a bank here in Sweden. We're looking at introducing logging for all transactions coming in (via API's, SOAP services, whatever).
The number of rows will probably be 2-5M per day. We have a log at the moment (just to give an idea of where we're coming from) which is defined as: -

Code:

COLTYPE   LENGTH
CHAR       50
VARCHAR    32000
CHAR       8
SMALLINT   2
DECIMAL    10
CHAR       7
CHAR       36
INTEGER    4
INTEGER    4
SMALLINT   2
CHAR       1
SMALLINT   2
TIMESTMP   10


We're running under CICS and have various thoughts including: -

    write each log record to a file and then load the table at night
    specify multiple partitions and write to them based on (?) last digit in current timestamp
    specify no indexes for the table
    is there a method to write "append" so a table to any new row is added at the back-end
    others ...


This can't (isn't) anything new, but other peoples' experience/ideas would be gratefully received
_________________
Michael
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12354
Topics: 75
Location: San Jose

PostPosted: Mon Sep 27, 2021 8:15 pm    Post subject: Reply with quote

misi01,


A few suggestions to mimic Logging.

1. Modify the table to have the timestamp field to 26 bytes, so that you get more granular. Currently you only have 10 byte field which I assume is just a date field.

2. Add another new column as SOURCE of Varchar of 1000 bytes so that you can store as much data as possible about incoming transaction ( terminal id , geo location...)

Alternatively you can have all the transactions loaded into a TDQ and offload it a to a daily GDG which then gets rolled into MONTHLY/YEARLY GDG.

You will always have an option of rolling back the transactions at any time.

Apart from that you can turn on logging and I suggest that you read this excellent article about Db2 for z/OS Log Overview
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
misi01
Advanced


Joined: 02 Dec 2002
Posts: 614
Topics: 171
Location: Stockholm, Sweden

PostPosted: Tue Sep 28, 2021 2:01 am    Post subject: Reply with quote

Thanks for the link. Time to start reading ....
_________________
Michael
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Database All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group