Forum Discussion

AanokhiGupta's avatar
AanokhiGupta
Qrew Member
5 months ago

Issue with copying the blank/null value of one field to another through pipeline

I am trying to copy a value from one field to another through pipeline. There are 2 scenarios:
When the value in first field is non-blank the value is getting copied form one field to 2nd field successfully.
But when the value of first field is blank or null, the null value is not getting copied from 1st to 2nd field.

Regards



------------------------------
Aanokhi Gupta
------------------------------

2 Replies

  • A pipeline will typically ignore blank values for what I imagine is efficiency sake. In your example - if the value in Record 1 is blank/null - do you want the result of that to be to actually blank out the value in Record 2? You could consider something like an if statement for your value that if the value of your field is populated, pass it in, otherwise pass in the Pipeline syntax for {{CLEAR}} so that the Pipeline knows you actually want that value gone. 



    ------------------------------
    Chayce Duncan
    ------------------------------
  • Chayce is exactly right. I ran into this myself, and it's a bit annoying. Here is the syntax you will need in Pipelines. Instead of simply copying the value (lets use a field called [Date] for the example).

    Instead of {{a.date}}, you will use either

    {% if a.date is none %}
    {{ CLEAR }}
    {% else %}
    {{a.date}}
    {% endif %}

    Or you can use this more condensed version:

    {{ CLEAR if a.date is none else a.date }} 



    ------------------------------
    Mike Tamoush
    ------------------------------