Excel - IF Function Problem - Expert Solution

Question description:
This user has given permission to use the problem statement for this blog.

Sheet 1 col A = Employee number col B = Employee first Name col C = Employee surname col D = Full/part time col E = Yearly Salary Col F = Monthly pay Sheet 2 col A = Employee first Name col B = Employee surname col C = Dept col D = Payroll number col E = Full/Part time col F = Monthly pay Col G = I need a formula that looks at the data on sheet 1 and if the payroll number matches that on sheet 2 and column E in sheet2="full time" then return the corresponding employees Yearly salary from sheet 1, If payroll number matches but column E ="part time" then do monthly pay x 12. If none return 0. Please can anyone help?
Solved by D. U. in 14 mins
This is the chat thread from the real Excelchat help session. It contains no private user information.
Excelchat Expert 02/05/2018 - 04:25
Hello, welcome to got it pro.
Excelchat Expert 02/05/2018 - 04:25
I believe you need help with payroll calculation.
Excelchat Expert 02/05/2018 - 04:25
User 02/05/2018 - 04:25
Excelchat Expert 02/05/2018 - 04:25
Please send me the file.
User 02/05/2018 - 04:26
I am unable to send the file as it has people personal data in
Excelchat Expert 02/05/2018 - 04:27
Then at least you can show me some sample data, right?
User 02/05/2018 - 04:27
Excelchat Expert 02/05/2018 - 04:27
thanks, please do it.
User 02/05/2018 - 04:29
So in sheet 2
User 02/05/2018 - 04:29
column F
Excelchat Expert 02/05/2018 - 04:30
User 02/05/2018 - 04:31
If payroll number = that on sheet 1 and Column E="full time" then return salary from sheet 1 column D. If payroll number = that on sheet 1 and column E ="part time" then do Gross pay from sheet 1 x 12.
Excelchat Expert 02/05/2018 - 04:33
okay, please give me a couple of minutes.
User 02/05/2018 - 04:33
Excelchat Expert 02/05/2018 - 04:37
=IF(E2="part time",VLOOKUP(D2,Sheet1!A:F,6,false)*12,VLOOKUP(D2,Sheet1!A:D,4,false))
Excelchat Expert 02/05/2018 - 04:37
Here is the required formula.
User 02/05/2018 - 04:37
That's much easier then I thought it would be. I was close with it
Excelchat Expert 02/05/2018 - 04:37
You are awesome.
Excelchat Expert 02/05/2018 - 04:37
Any question?
User 02/05/2018 - 04:38
No think that's it!
User 02/05/2018 - 04:38
Think I was over complicating it
Excelchat Expert 02/05/2018 - 04:38
If you think I was helpful, please rate me 5 star.
Excelchat Expert 02/05/2018 - 04:39
We all kind of prone to over complicate things time to time. aren't we? Its no big deal.
Excelchat Expert 02/05/2018 - 04:39
To rate me please close this session.
User 02/05/2018 - 04:39
OK thank you
Excelchat Expert 02/05/2018 - 04:39
Thanks and have a great day ahead!

This is the output file from the real Excelchat help session:
This is an example of the expert help you can get. It contains no private user information.

Get instant expert help with Excel and Google Sheets

Post your problem and you’ll get expert help in seconds.

Your message must be at least 40 characters
Your privacy is guaranteed. Your session will not be used for blog unless you give us persmission.

Click here to get your free Excelchat help session

Subscribe to Excelchat.co
Trusted by people who work at
Amazon.com, Inc
Facebook, Inc
Accenture PLC
Siemens AG
The Allstate Corporation
United Parcel Service
Dell Inc