Welcome to the Oracle community forum and interact with 2 million technical staff. 1. first in sys. odbc. configure a DSN #################################### ################## [ttdemo] DriveroptTimesTentt70liblibtten. soDataStorevarTimesTentmpttdemoDatabaseChar
Welcome to the Oracle community forum and interact with 2 million technical staff> enter 1. first in sys. odbc. configure a DSN #################################### ################## [ttdemo] Driver =/opt/TimesTen/tt70/lib/libtten. so DataStore =/var/TimesTen/tmp/ttdemo DatabaseChar
Welcome to the Oracle community forum and interact with 2 million technical staff> enter
1. configure a DSN in sys. odbc. ini.
######################################## ############### [Ttdemo] Driver =/opt/TimesTen/tt70/lib/libtten. so DataStore =/var/TimesTen/tmp/ttdemo DatabaseCharacterSet = WE8ISO8859P1 TempSize = 20 PermSize = 20 Authenticate = 0 UID = test OracleID = shacola OraclePwd = 123456 Logging = 1 Isolation = 1 PassThrough = 0 LockLevel = 0 TypeMode = 0 ######################################## ############### |
2. Create an Oracle test table and prepare data
Sqlplus test/123456
Create table readtab (a number not null primary key, B VARCHAR2 (31 ));
Insert into readtab VALUES (1, 'Hello '); Insert into readtab VALUES (2, 'World '); COMMIT; |
3. Create a cache group
Ttisql ttdemo Call ttCacheUidPwdSet ('test', '20140901 '); Call ttCacheStart;
Create readonly cache group readcache Autorefresh interval 5 SECONDS FROM readtab (A number not null primary key, B VARCHAR2 (31 )); |
4. load data
Load cache group readcache commit every 256 ROWS;
SELECT * FROM readtab; |
5. Insert new data into the source table
Sqlplus test/123456 Insert into readtab VALUES (3, 'Hello '); Insert into readtab VALUES (4, 'again '); COMMIT; |
6. Check whether the cache is refreshed.
Wait for the time specified by autorefresh interval. In this example, It is 5 seconds.
7. Check whether the test is complete.
Drop cache group readcache;
Call ttCacheStop; |