Skip to main content

Hello everyone,

we are having a problem with the sync rule of a table:

 

Ownership Query:

<hierarchy_select>
 <primary_table>c_task_assignment_view</primary_table>
 <from>
  <table>c_task_assignment_view</table>
 </from>
 <attrs>
  <attr>c_task_assignment_view.person_id</attr>
 </attrs>
 <where>
  <data_constraint>
   <constraint>
    <left_operand>c_task_assignment_view.task_id</left_operand>
    <operator>eq</operator>
    <right_operand>{task_id}</right_operand>
   </constraint>
  </data_constraint>
 </where>
</hierarchy_select>

 

Initial Query:

<hierarchy_select return_only_requested_attrs="true" max_rows="50000">
  <primary_table>C_WBS_CODE_TASK</primary_table>
  <attrs>
    <attr>C_WBS_CODE_TASK.*</attr>
    <attr>C_WBS_TASK_VIEW.*</attr>
  </attrs>
  <from>
    <table>C_WBS_CODE_TASK</table>
    <table>C_WBS_TASK_VIEW</table>
  </from>
  <where>
     <data_constraint>
        <constraint>
          <left_operand>C_WBS_CODE_PERSON_VIEW.person_id</left_operand>
          <operator>eq</operator>
          <right_operand>{person_id}</right_operand>
        </constraint>
    </data_constraint>
    <join_constraint>
      <constraint>
        <left_operand>C_WBS_CODE_TASK.task_id</left_operand>
        <operator>eq</operator>
        <right_operand>C_WBS_CODE_PERSON_VIEW.task_id</right_operand>
      </constraint>
    </join_constraint>
    <join_constraint>
      <constraint>
        <left_operand>C_WBS_TASK_VIEW.task_id</left_operand>
        <operator>equi</operator>
        <right_operand>C_WBS_CODE_TASK.task_id</right_operand>
      </constraint>
    </join_constraint>
  </where>
</hierarchy_select>

 

Related Query:

<hierarchy_select return_only_requested_attrs="true" max_rows="50000">
  <primary_table>C_WBS_CODE_TASK</primary_table>
  <attrs>
    <attr>C_WBS_CODE_TASK.*</attr>
    <attr>C_WBS_TASK_VIEW.*</attr>
  </attrs>
  <from>
    <table>C_WBS_CODE_TASK</table>
    <table>C_WBS_TASK_VIEW</table>
  </from>
  <where>
      <data_constraint>
        <constraint>
          <left_operand>C_WBS_CODE_TASK.task_id</left_operand>
          <operator>eq</operator>
          <right_operand>{task_id}</right_operand>
        </constraint>
     </data_constraint>
     <join_constraint>
      <constraint>
        <left_operand>C_WBS_TASK_VIEW.task_id</left_operand>
        <operator>equi</operator>
        <right_operand>C_WBS_CODE_TASK.task_id</right_operand>
      </constraint>
    </join_constraint>
  </where>
</hierarchy_select>

 

The idea is, that if the table C_WBS_CODE_TASK changes (adding row, changing row, deleting row) the table and the corresponding view C_WBS_TASK_VIEW will get synchronized to the mobile device in real time.So far, the ownership query correctly sends only relevant rows. Furthermore, new rows in C_WBS_CODE_TASK get synchronized in real time and C_WBS_TASK_VIEW also shows the new data correctly on the mobile client.

But if entries get deleted or changed in the SC/WC, the data still stays available on the mobile client, means the table does not get correctly updated.

As a side information, the edditing of the C_WBS_CODE_TASK table only happens on the SC/WC. On WC data is only shown.

Has anybody an idea how these changes can get synchronized to the mobile client in real time? I suspect it referes to the “Related Query”, but i am not sure what i am missing.

with kind regards,
Michael

Be the first to reply!

Reply