cancel
Showing results for 
Search instead for 
Did you mean: 

Query Cache Duration

Former Member
0 Kudos

Hi,

I'm using SAP MII 12.2 and I need to keep a cache XacuteQuery for 24 hours. I'm setting the "Use Query Caching" with true value, "Cache Duration" with 24 and "Cache Duration Units" with "H". The cache operates normally, but after a few hours the cache is clean, not remaining in memory for 24 hours.


Thanks,

Luís Felipe Lacerda

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Does your XacuteQuery is based on Dates?

Don't use date ranges (time sensitive) when caching a query. Query caching will not work.

The reason behind this is to prevent large quantities of repetitive data from being stored in the MII cache.

Source: http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/f08d7ae2-6f56-2c10-50b4-8a3bb1d43...

Former Member
0 Kudos

pt:

Guilherme,

agradeço a resposta. Mas não estou usando XacuteQuery baseada em data. A XacuteQuery chama uma Trasaction e esta busca alguns dados que dificilmente mudam e faz alguns cálculos. Essa XacuteQuery está no Scheduler e roda todo dia a meia-noite e tem um cache com duração de 24h. Minha intenção era que durante o dia a Transaction não fosse executada. Porém, algumas horas depois, executando a mesma XacuteQuery com exatamente as mesmas entradas, a transaction é executada.

en:

Guilherme,

thanks for reply. But i don't use XacuteQuery based on date. The XacuteQuery calls a Transaction that search some data that don't change frequently and calculates informations. This XacuteQuery is in the Scheduler and run every day at midnight and has cache duration of 24h, in order for the transaction not run throughout the day. However, a few hours, running the same XacuteQuery with the same inputs , the transaction is executed.

Former Member
0 Kudos

pt:


Voce poderia fazer uns testes?

Rodar duas vezes a mesma Xacute direto do Scheduler e ver se roda do cache.

Rodar duas vezes a Xacute manualmente e ver se a transaction é executada do cache.

Se não rodar do Cache, tenta alterar o Query Caching de 24 H para 1 D.

Isso pode ser um problema com o Scheduler.

En:

Could you run some tests?

Run the same XacuteQuery twice directly from the Scheduler and see if runs the Transaction from cache.

Run the same XacuteQuery manually e see if the Transaction runs from cache.

If it does not run from cache, try changing the Query Caching from 24H to 1 D.

This might be a problem with the MII Scheduler.

Former Member
0 Kudos

pt:

Rodando a XacuteQuery tanto pelo Scheduler quanto manualmente, obtive os mesmo resultados:

Primeira execução, resultado NÃO derivou do cache.

Segunda execução (logo em seguida), resultado derivado do cache.

Terceira execução (1 hora após), resultado derivado do cache.

Quarta execução (6 horas após), resultado NÃO derivou do cache.

en:

Running the XacuteQuery both the Scheduler or manually, got the same results:

First run, the result is NOT derived from cache.

Second run (just after the first run), the result is derived from cache.

Third run (1 hour after), the result is derived from cache.

Fourth run (6 hours after),  the result is NOT derived from cache.

agentry_src
Active Contributor
0 Kudos

PT:

Você já pensou em usar uma consulta MDO em vez de cache? Não seria limitado a um único dia, mas vai atualizar (dependendo de suas configurações), como os dados foram alterados.

EN:

Have you thought about using an MDO query instead of caching?  It would not be limited to a single day, but would update (depending upon your settings) as the data changed.

Regards, Mike

Answers (0)