Hello,

we are implementing a questionnaire tool for companies. I would like to import the data using a DIH.

To increase performance i would like to use some caching. But my solution is not working. The score of my

questionnaire is empty. But there is a value in the database. I've checked that.

We can mark questionnaires for special purposes. I need to import the special mpc score. The mpc questionnaire

is not changing while importing. So i thaught i can can cache this value for usage in mpc_score queries.

Can you please help me, to find out what i'm doing wrong here?

Thanks

Per

    <document>
        <entity
            name="company"
            query="SELECT id as ID,
                          customer_number as CUSTOMER_NUMBER
                    FROM  companies
                   WHERE  '${dataimporter.request.clean}' != 'false'
OR last_modified > '${dataimporter.last_index_time}'">
            <entity
                name="mpc"
processor="SqlEntityProcessor" cacheImpl="SortedMapBackedCache"
                query="select qp.questionnaire AS ID
                       from questionnaire_purposes qp
                       join purposes p ON qp.id = p.id
                       where p.name = 'mpc';">
                <entity
                    name="mpc_score"
                    query="select c.score as SCORE
                           FROM basfcdi.census c
                           where c.company=${company.ID}
                           and c.questionnaire = ${mpc.ID};">
                    <field name="mpc_score" column="SCORE" />
                </entity>
            </entity>
    </entity>

</document>

Reply via email to