Several alternatives:
1) use your programming language to locate the the "<span" string and then extract all characters up to but not including the point you have just found
2) the simple regex answer is:
^([^<]*)<span
and look at match group #1. However, this will also grab any other tags etc. that come before the '<span' text such as "<abc/>text that I want<span id="qwe"></span>" will return "<abc/>text that I want".
3) using the pattern:
(?<=>|^)([^<>]*)<span
which will solve the above issue. It assumes that you are only dealing with a single line (if not, then add "\n" into the character set).
Susan