Hello Statalist,

Please forgive me if this is a stupid question; I am new to Stata. I am working with a dataset that has one variable listing the names of businesses and another listing the names of the towns in which the businesses are established. I want to test the business names for whether or not they contain the name of their respective towns. For example, if the name of the business is "Corinth Lumber Co." and the business is in Corinth, I want that to come back positive. Furthermore, I would like to create a binary variable on the same dataset to house the results, with 1 for positive and 0 for negative. Any advice for how I would go about doing this? I really don't know where to start.