Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tutorial on Regular Expressions?

Status
Not open for further replies.

MMNZ

Technical User
Jul 30, 2001
4
NZ
Hi,

Can anyone suggest a good on-line source for information about MySQL Regular Expressions? I have an excellent book on MySQL, and it gives many examples, but it is not quite as comprehensive as I was hoping.

The root of my problems start with values in a column that have a start value and a stop value seperated by a dash ("-").

For example:

9-123
19-777
1-1450
0-7

(this data will NEVER contain negative numbers)

I am wanting to grab the number before the dash, and then grab the number after the dash (in seperate parts of my SELECT statement)...

I have found a LONG work around using MySQL commands like LENGTH, RIGHT, LEFT,...

I was hoping for a "cleaner" solution, and I was hoping to use RegExps like I would in Perl.

Thanks for your help finding a tutorial or in assisting me with my query.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top