Welcome Guest! Log in
×

Notice

The forum is in read only mode.
Due to some maintenance operations, stambia.org will be switched to read-only mode during the 13th November. It will be possible to read and download, but impossible to post on the forums or create new accounts. For any question please contact the support team.

Topic-icon Question Aggregate Fields

More
19 Feb 2016 13:59 #1 by Afaf ABOUTABIT
Afaf ABOUTABIT created the topic: Aggregate Fields
Hello,

I want to do use some aggregate functions on some fields in my mapping, the target table is as follows



But I get an error while integration, saying that "GROUP BY, à la position 0, n'est pas dans la liste SELECT"
When I check the code generated, I can see the reason why, here is a part of the code generated, the group by part :
group by 0, split_part(date.c2, ':', 2)::date, eb_party.eb_party_num, split_part(carrier.c3, ':', 1), 0, split_part(pickslip.c3, ':', 1), current_timestamp

Can anybody please help me figure out this problem ?
Attachments:
More
19 Feb 2016 15:30 #2 by Thomas BLETON
Thomas BLETON replied the topic: Aggregate Fields
Hi,
This is probably due to the presence of the "0" value in the taxable_weight and origin mapping expressions.
These columns are mapped on the staging area. Can you try mapping them on the target instead ? This should exclude these values from the Pre-integration / integration select queries.
More
19 Feb 2016 16:07 #3 by Afaf ABOUTABIT
Afaf ABOUTABIT replied the topic: Aggregate Fields
Merci Bien ! vous avez raison ça marche maintenant :-)