Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • Pattern Matching using REGEXP

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 423
    Comment on it

    REGEXP:

    It is similar to LIKE which is used to fetch data based on regular expression from a table.

    Syntax:

    SELECT  columnname(s) FROM  tablename WHERE columnname REGEXP pattern;
    

    Example 1:

    SELECT name FROM Employee WHERE name REGEXP 'sh$';
    

    This query will find those names from Employee table who are ending with "sh". Like it will fetch name like Mahesh , Avnish etc.

    Example 2:

    SELECT name FROM Employee WHERE name REGEXP 'am';
    

    This query will find those names from Employee table who contains "am" like Amit , Abraham etc.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: