May 10, 2023 11:07 AM
Hello!
I'm making a table to generate contracts. Sometime there is 1 name on the contract, sometime 2.
List of my columns :
Name 1
Name 2
And (just a formula for write "and" in the column).
I'm trying to find the good way to write the formula of my and column :
Thanks for your reading!
Have a nice day.
Solved! Go to Solution.
May 10, 2023 11:36 AM
You want to put the word " and " between the two names, if there are two names?
If either name could be present, eg. {Name 2} without a {Name 1}.
CONCATENATE(
{Name 1},
IF( AND({Name 1}, {Name 2}), " and "),
{Name 2}
)
If {Name 2} only appears if there is also a {Name 1}
CONCATENATE(
{Name 1},
IF( {Name 2}, " and " & {Name 2})
)
May 15, 2023 12:32 PM
> Not really, I wants to show the word "and" in my formula only if the field "name 2" is notblank 🙂
That's what my formulas do. Did you try them? If they do not give the results you want, could you send screen shots?
May 10, 2023 11:36 AM
You want to put the word " and " between the two names, if there are two names?
If either name could be present, eg. {Name 2} without a {Name 1}.
CONCATENATE(
{Name 1},
IF( AND({Name 1}, {Name 2}), " and "),
{Name 2}
)
If {Name 2} only appears if there is also a {Name 1}
CONCATENATE(
{Name 1},
IF( {Name 2}, " and " & {Name 2})
)
May 10, 2023 12:09 PM
Not really, I wants to show the word "and" in my formula only if the field "name 2" is not blank 🙂
May 11, 2023 11:09 PM - edited May 12, 2023 04:33 AM
I know i'm close !
=IF(OR({Name 2}=BLANK(),CONCATENATE({Name 2},{And}),CONCATENATE({Name 2},", ",{And}))
Any idea @kuovonne ? 🙂
May 15, 2023 12:32 PM
> Not really, I wants to show the word "and" in my formula only if the field "name 2" is notblank 🙂
That's what my formulas do. Did you try them? If they do not give the results you want, could you send screen shots?
May 15, 2023 11:05 PM
Hello!
It works, I do not know how I managed but I did not get the right result by testing the first time!
Thanks a LOT 🙂