Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!hsdndev!dartvax!L.Carl.Pedersen From: L.Carl.Pedersen@dartmouth.edu (L. Carl Pedersen) Newsgroups: comp.databases Subject: Re: Detecting changes to Oracle tables Message-ID: <1991May29.205205.3489@dartvax.dartmouth.edu> Date: 29 May 91 20:52:05 GMT References: <1213@keele.keele.ac.uk> Sender: steve@dartvax.dartmouth.edu (Steve Campbell) Organization: Dartmouth College, Hanover, NH Lines: 20 In article <1213@keele.keele.ac.uk> csa09@seq1.keele.ac.uk (P. Singleton) writes: > In long-running processes which frequently access particular UNIX files > (e.g. the password file), I am accustomed to 'caching' the file's > contents within the process and noting it's time-of-last-modification (TOLM). > > Subsequent accesses to the file need only check the file's current TOLM > (cheap, if the inode is incore), and use the cached data if the file is > (apparently) unmodified (else they re-cache the data and timestamp). > > I want to do a similar thing with some Oracle tables which I must frequently > refer to from within a (Prolog and C) program This is a terrible kludge, and requires DBA privileges, but you could do an ALTER TABLE BACKUP every time you refresh your cache, and then check BACKED_UP in USER_TABLES, to see if it's been modified since the last time. This may degrade performance, but probably only slightly. Also, of course, you will need to make allowances for this kludge if you are using INCTYPE=CUMULATIVE or INCTYPE=INCREMENTAL with EXPort.