Hi,

Use a regular expression:

p subject[/^gidNumber: (\d+)/, 1]

-- 
Posted via http://www.ruby-forum.com/.