Title: how to adding this formula in excel sheet
Tags: excel-2007
Question: I want to make formula in excel like below:
If values of column A have abc then put a number i.e 1 in column B, and I am doing like below:
IF(A="abc") then (B=1)
but its not working.
kindly suggest me, waiting for reply.
Thanks


Here is another answer: In B1 enter:
=IF(A1="abc",1,"")
and copy down.

Here is another answer: Use the below formula in column B1.
=IF(A1="abc",1,0)
The above formula will manipulate the value of cell A1
and if that is "abc" then the value of B1 will become 1 else 0.
Comment for this answer: If you dont want to use 0 then try formula =IF(A2="abc",1). But this will return FALSE if the value is not "abc"
Comment for this answer: but I don't to put `0` in other cell, I want to left blank on other cell
Comment for this answer: I want like put column `B=1` where `A="abc"`
Comment for this answer: yes, this answer is working, but not for my condition
Comment for this answer: @user88 Do you know excel? the given answer is working.

{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 2, 'CommentCount': 0, 'ContentLicense': 'CC BY-SA 3.0', 'CreationDate': '2015:00:01/01/15', 'FavoriteCount': None, 'PostTypeId': 1, 'Tags': '<excel-2007>', 'Title': 'how to adding this formula in excel sheet', 'ViewCount': 91, 'id': 27729172, 'user_AboutMe': '', 'user_AccountId': 2191912.0, 'user_DisplayName': 'user88', 'user_Reputation': 1144.0, 'user_Views': 158.0, 'user_id': 1938702.0}}