# How to write multiple IF statement

1. ## How to write multiple IF statement

I have many part numbers which may be duplicated and I want to sum the qty shipped based on a few criteria. How would I write this?

IF N4=C4 and K4 =T1 then sum F:F.

2. ## Re: How to write multiple IF statement

Without a context, the formulas you posted don't have much meaning. Can you describe the criteria for us and post some sample data?

3. ## Re: How to write multiple IF statement

The attached file shows the data that I am talking about. N4 in my initial post should be M4.

Column M is the part number that I want to use as my reference part number.
Column C is the part number based on lines sold, it could be input many times.
Column K is the month shipped.
T1 is the reference month that I used to illustrate the dollar amount sold.

For example I would like to see if part number in M4 (example) matches date in column c and T1 matches K4 then sum the data in column F. The ultimate goal is I want to illustrate each month and the dollar amount sold for each part number. The problem is that I might have part number 122345 (example) listed 100 times and it needs to be summed under the correct month.

Thanks for the help.

No ideas???

5. ## Re: How to write multiple IF statement

So in your example, "IF M4=C4 and K4 =T1 then sum F:F" (note: it should be S1 not T1 as you have merged cells) where is this result going? U4?

In any case, try this formula
=SUMPRODUCT(--(\$C\$2:\$C\$500=\$M4),--(\$K\$2:\$K\$500=S\$1),(\$F\$2:\$F\$500))

Does that work for you?

6. ## Re: How to write multiple IF statement

I think that will work. I have plugged it in and played with it a little. I think it might just get me to where I need to be. The main thing I needed was how to combine the conditions. You are awesome...Thanks a TON, I have been

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1