Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member

Hello,

Intro

Questions that come up frequently with regard to SUP based applications are;

  • The user does not see this data on his device; is this record in the SUP cache? 
  • Has this operation caused a cache refresh?
  • Is there something wrong with the cache?  Is it in a healthy state?
  • ..

I am sure a lot of you have already looked at the SUP cache to answer these questions but so far I have not found a step-by-step description of how to do it.

So, here it is.

Where can I find the SUP cache?

The SUP cache is located in the SQLAnywhere database that is installed as part of the SUP.

It's name is (by default); default-cdb.

For a single node SUP 2.1 (and earlier, I suppose) you can find the files on; <Sybase Install Directory>\UnwiredPlatform\Servers\SQLAnywhere12.

How can I access the SUP cache?

There are multiple ways of doing this - here are 2 ways that you can do this;

1. Using Sybase Unwired Tooling

2. Using Sybase Central

You find a description of both approaches in this document; http://scn.sap.com/docs/DOC-31091

How do I identify the right SUP cache database table to look in?

When you look at the list with tables that are available in the cache, it's not always straightforward to find the appropriate table to look in.

Let's say you have an MBO named "Customer", how to find the right database table to look in?

First you have to know the MBO package name that this MBO is part of and that was used to deploy this MBO;

After that, navigate to this folder;

<Sybase Install Directory>\UnwiredPlatform\Servers\UnwiredServer\deploy\<MBO package name>\merged

Here you will find a file called "ds-deploy.xml".

In this file look for a line with the MBO name ("Customer", for example).

You will find a line starting with "<virtualTable " referencing the "Customer"-MBO.

In this line you will find the cache database table name to look for; just look for the "name"-attribute.

(d1_customermaplist01_1__58525 in this case).

How do I look at the contents of the SUP cache database table?

1. Using Sybase Unwired Tooling

Expand the "Tables" node and look for the appropriate table (d1_customermaplist01_1__58525 in this case)

Right click and select "Edit Data";

Now a popup will appear where you can select which data to select.

(please note that the selection is limited to 100 records by default, but you can change that)

After confirming this popup, a view on the contents of the database table will appear;

2. Using Sybase Central

After being connected to the cache db table (default-cdb), click on "Tables" and then look for the appropriate table;https://community.wdf.sap.corp/sbs/servlet/JiveServlet/showImage/38-65911-66837/syce+tables.png

By double clicking this line and then navigating to the last tab on the following screen, you can have a look at what's inside this table.

What other information can I find in the cache?

  • In the tables containing the MBO data, you will find a column called "Partition ID".

       This is an indication of the cache partition this line is in. 

     Cache partitions can be made because of a sync parameter mapped to a load argument or because of the "Partition by requestor and device identity" on the cache group policy, for example.

  • In the tables containing the MBO data, you will find a column called "LMD".

     This is the timestamp of the latest update of this line in the cache.

     If you want to know if a line was updated after an operation, check this value before and after the operation.

  • After you find a table holding MBO-data, you will also find a table with the same name, ending in "sk";

       d1_customermaplist01_1__58525_sk, for example. 

     For certain synchronization scenarios, here you can find client id's; these are the clients that were involved with the update of this cache db table.

     In the SCC, you can also find this client id when navigating to the relevant package and check the subscription-tab, where you can also see the client id.

  • Using the Sybase Central, a lot more information is available like indexes for example.

     Also, a general look at the state of the database is availble.

     Just select the root node of the database and click the "Overview" tab in the detail screen;

     If there's something wrong with the database, you can find out about it here. 

That's it.

All the above information is based on SUP 2.1.3, but it's also applicable to previous versions.

If you have useful information to add to this (and I am sure you do), please don't hesitate to share them here.

Thanks,

Have a nice day,

Wim

2 Comments