![]() |
Mysql help [find/replace]
Is there any way in the regular expresion for doing a "any character" find
In other words if I want to search for any word beginning with A and ending in Z but with any two characters inbetween for example A12Z or AcdZ or A:3Z is there any way of doing it.. Just thought I;d ask as I do have a way of doing it to an SQL dump but wanted to know if I could do it directly via either command line or phpmyadmin |
Re: Mysql help [find/replace]
select * from tablename where columnname like 'A%%Z'
|
Re: Mysql help [find/replace]
Cool :) will give it a try
Thank you |
Re: Mysql help [find/replace]
You dont need 2 %'s
Also note that that A%Z will match AxxZ or AZ or AxxxxxxxxxZ If you want it to be just two chars use _ i.e. A__Z |
Re: Mysql help [find/replace]
Quote:
Whoops, didnt mean to put two % in (although it would still work). Must admit i had assumed that the column was 4 chars in width |
Re: Mysql help [find/replace]
Paul, thank you very much, exactly what I was after..
|
| All times are GMT +1. The time now is 09:03. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
All Posts and Content are © Cable Forum