SOLVED

OR In an IF function

Copper Contributor
Hi,

I have two columns containing serial numbers.

I need a function which states that if the first column ends in either 616 or 796, take that column’s serial number and if it ends in neither, take the second column’s serial number.

Is there a function I can use to do this?
5 Replies
best response confirmed by Judy Tran (Copper Contributor)
Solution

Hi Judy

 

You'll need a formula to do what you are proposing.

 

I've drafted this formula, see if it does the job for you?

 

=IF(OR(RIGHT(A2,3)="616",RIGHT(A2,3)="796"),A2,B2)

 

A2 represents the first value in your First column.

B2 represents the second value in your Second column.

 

Replace the cell references with your desired ones.

 

I've also attached a same of the worksheet I've made for you to see it in action.

 

Let me know if this did the trick?

 

Cheers

Damien

Yes, that’s perfect! Thanks so much for your help!
Happy to help!

All the best
Damien

I need a formula which states: if one or the other are false, then No.  if the value in cell1 is greather than 50 or the value of cell #2 is Y, then Y if not, N

but

If the value of cell #2 is Y, then Y no matter what...guh

Hi Synnovea

If you are able to start a new conversation and attach a sample file, I/the other users here can assist.

Your conditions will be clearer if we can see how you are set up.

Cheers
Damien
1 best response

Accepted Solutions
best response confirmed by Judy Tran (Copper Contributor)
Solution

Hi Judy

 

You'll need a formula to do what you are proposing.

 

I've drafted this formula, see if it does the job for you?

 

=IF(OR(RIGHT(A2,3)="616",RIGHT(A2,3)="796"),A2,B2)

 

A2 represents the first value in your First column.

B2 represents the second value in your Second column.

 

Replace the cell references with your desired ones.

 

I've also attached a same of the worksheet I've made for you to see it in action.

 

Let me know if this did the trick?

 

Cheers

Damien

View solution in original post