I would like to display the contents of two ConfiForms tables with the same structure in a combined view.
Example
Although this seems to be a very simple question, I have not been able to achieve this. I'd greatly appreciate if anybody can show me a solution. Thanks.
Hi
It is indeed a quite simple task in our opinion... And the TableViewMerger is the macro to use
However, you need to be careful with ConfiForms Field macros that you have as these are used as "grouping keys"
So, you want to merge the data from different forms and in this case it would be greate to add a field that has a unique value, and that is an "id" field
Add a ConfiForms Field with field name set to id
And mark it to be used as "key"
Alex
Thanks a lot for this tip! I will use it in my merged tables in the future.
In the meantime, we found the cause of my problem (see my related comment). And now that I know how to use the Table Merger macro properly, I would say: you are right, it is indeed quite a simple and intuitive task! 😅
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here's what I did: I wrapped two TableView macros with the TableView Merger macro. This would be intuitive in my opinion. Unfortunately, the result was not as expected.
I have tried some of the settings in the TableView Merger macro, but without success.
And just to clarify what I expected (unfortunately only obtained by editing the above image):
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
A colleague showed me what was wrong in my code: I just had to empty the body of the TableView macros and put the Field and Edit Controls macros directly into the body of the Table Merger macro.
So, instead of using this code:
I just have to use the code below and everything works as expected:
Since I have always used the TableView macro in the past with field and edit control macros in its body, I would never have thought of this! I was not even aware that you could use the TableView macro with an empty body. 🤦♂️
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, but this way it will aggregate by "type" field - meaning that a record with the same value in the "type" field will be "skipped", counted, but skipped
You will see only the unique results by "type"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
do you mean that if the table values are as follows
this solution
should result in a table like so
because the second record with "B" will be skipped?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
At least in my test environment this is not the case. The displayed table looks like this:
Only when I add a field macro with fieldName=Count:([count]), the second record with "B" is not displayed anymore, because both "B" records are aggregated (I just wonder where the Edit Controls have gone in this table).
And if I add an additional field "id" as you suggested in your answer above, the result looks like this:
In all three cases, the result seems comprehensible to me and we can gladly close this topic. 😃✅
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Edit is not possible when you aggregate data - as... what will record you will edit in that case?
That is why the edit controls are gone on aggregated views
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are, of course, absolutely right! I had not thought of that. Thanks for your explanation!
Ulrik
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi @Alex Medved _ConfiForms_ and @Ulrik Schoth
curious if we can somehow identify where the data is from, ie form1 and form2, is there a solution for that?
Type, Form
A, Form1
B, Form2
....
thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In TableViewMerger ConfiForms creates virtual fields like this
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Any chance of side merger like if table 1 is A, B, C and table D, E, F
A D
B. E
C. F
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
How should ConfiForms know that A belongs to D, and etc? Do they share a "common key"?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.