Regular expressions - Mailing list pgsql-general

From Tumurbaatar S.
Subject Regular expressions
Date
Msg-id 001101c42058$85f67930$13670296@TUMURS
Whole thread Raw
Responses Re: Regular expressions
List pgsql-general
What does this '.{2,}' RE pattern mean?

1. 2 or more of any char
2. 2 or more of same char

I assume the answer is the 1st one. If yes,
how the 2nd's pattern should be look?

Thanks.

P.S.
I'm going to use CHECKs to make some basic validations of
email and passwords (5-15 chars):

CHECK (length(Email) = length(substring(Email from '.+@.+\..+')))

CHECK (length(Password) = length(substring(Password from
'[0-9_A-Za-z]{5,15}')))

Can anybody suggest shorter (or compatible with other RE engines) variants?
If possible using only Basic RE or if not, using ERE, but not ARE.


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Error in function to pg_dump: Standard in must be a tty
Next
From: "Siew Hui, Wong"
Date:
Subject: Re: Error in function to pg_dump: Standard in must be a tty