Robin Vickery schreef:
[snip]
Because each of your subpatterns can match an empty string, the
lefthand subpattern always matches and the righthand subpattern might
as well not be there.
Indeed they do, i did not realise that.
The simplest solution, if you don't want to completely rethink yo
On 30 October 2007 11:07, Stijn Verholen wrote:
> Hey list,
>
> I'm having problems with grouped alternative patterns.
> The regex I would like to use, is the following:
>
> /\s*(`?.+`?)\s*int\s*(\(([0-9]+)\))?\s*(unsigned)?\s*(((auto_i
> ncrement)?\s*(primary\s*key)?)|((not\s*null)?\s*(default\
On 30/10/2007, Stijn Verholen <[EMAIL PROTECTED]> wrote:
> Hey list,
>
> I'm having problems with grouped alternative patterns.
> The regex I would like to use, is the following:
>
> /\s*(`?.+`?)\s*int\s*(\(([0-9]+)\))?\s*(unsigned)?\s*(((auto_increment)?\s*(primary\s*key)?)|((not\s*null)?\s*(defau
Hey list,
I'm having problems with grouped alternative patterns.
The regex I would like to use, is the following:
/\s*(`?.+`?)\s*int\s*(\(([0-9]+)\))?\s*(unsigned)?\s*(((auto_increment)?\s*(primary\s*key)?)|((not\s*null)?\s*(default\s*(`.*`|[0-9]*)?)?))\s*/i
It matches this statement:
`id` INT
4 matches
Mail list logo