From: Farrel Lifson Date: 2008-07-29T23:11:52+09:00 Subject: Re: text comparision 2008/7/29 Karthic Ganesan : > now i need to check the text "Test" from variable a. > i have tried, > > b="Test" > if a== %b% > > and is no luck. > > could anybody know how to perform this task? Try using a regular expression: b = /Test/ if b =~ a # Do stuff end Farrel -- Aimred - Ruby Development and Consulting http://www.aimred.com