Combine

Combines two tables together into a single table. Matching records are replaced or summed.

Inputs

src
A value table.
with
A value table.

Outputs

answer
A value table.
sum_count
A scalar value table (default="null")

Comments

  • src, with, and answer must be of the same type, binding, and format.
  • If sum_count is specified, it must be a scalar table bound to the same entity type as src, with, and answer.
  • The sum_count argument controls how values from src and with are combined into answer.
    • If sum_count is “null”, answer will contain records from src and with. In the case where a matching record ID exists in both src and with, answer will contain the record from with.
    • If sum_count is a valid scalar table, it will contain a count for each record added to answer. In the case where a matching record ID exists in both src and with, answer will contain the sum of src and with.
  • Combine can be used to average values between two tables by dividing answer by sum_count.

Syntax

N/A

XML Example

<call name="Combine" src="src_tab" with="with_tab" answer="ans_tab" />