Task 6: Load Initial Data

Load the cache group.

  1. Start the ttIsql utility and connect to the cache1 DSN as the instance administrator.

    Grant the SELECT, INSERT, UPDATE and DELETE privileges on the sales.customers cache table to the TimesTen cache administration user so that this user can issue SELECT, INSERT, UPDATE and DELETE SQL statements on this table. The INSERT, UPDATE and DELETE privileges on the sales.customers table are required to run write through operations from the TimesTen cache table to the cached Oracle Database table.

    % ttIsql cache1
    Command> GRANT SELECT, INSERT, UPDATE, DELETE ON sales.customers TO cacheadmin;
    Command> exit;
    Disconnecting...
    Done.
  2. Start the ttIsql utility and connect to the cache1 DSN as the TimesTen cache administration user.

    Perform a LOAD CACHE GROUP statement for the first load of the AWT cache group since the cache tables are empty.

    % ttIsql "DSN=cache1;UID=cacheadmin;PwdWallet=/wallets/cacheadminwallet"
    Command> LOAD CACHE GROUP awt_customers COMMIT EVERY 256 ROWS PARALLEL 3;
    2 cache instances affected.
  3. Query the contents of sales.customer cache table.

    Command> SELECT * FROM sales.customers;
    < 122 West     Jim Johnston >
    < 663 MidWest  Pat Reed >
    2 rows found.
  4. Use the ttIsql cachegroups command to view the definition of the awt_customers cache group:

    Command> cachegroups;
    
    Cache Group CACHEADMIN.AWT_CUSTOMERS:
    
      Cache Group Type: Asynchronous Writethrough
      Autorefresh: No
      Aging: LRU on
    
      Root Table: SALES.CUSTOMERS
      Table Type: Propagate
    
    1 cache group found.