Code Duplication    Length = 2-2 lines in 2 locations

lib/Doctrine/DBAL/Platforms/SQLAnywherePlatform.php 2 locations

@@ 1122-1123 (lines=2) @@
1119
        $pattern = "'%[^' + $char + ']%'";
1120
1121
        switch ($pos) {
1122
            case self::TRIM_LEADING:
1123
                return 'SUBSTR(' . $str . ', PATINDEX(' . $pattern . ', ' . $str . '))';
1124
            case self::TRIM_TRAILING:
1125
                return 'REVERSE(SUBSTR(REVERSE(' . $str . '), PATINDEX(' . $pattern . ', REVERSE(' . $str . '))))';
1126
            default:
@@ 1124-1125 (lines=2) @@
1121
        switch ($pos) {
1122
            case self::TRIM_LEADING:
1123
                return 'SUBSTR(' . $str . ', PATINDEX(' . $pattern . ', ' . $str . '))';
1124
            case self::TRIM_TRAILING:
1125
                return 'REVERSE(SUBSTR(REVERSE(' . $str . '), PATINDEX(' . $pattern . ', REVERSE(' . $str . '))))';
1126
            default:
1127
                return
1128
                    'REVERSE(SUBSTR(REVERSE(SUBSTR(' . $str . ', PATINDEX(' . $pattern . ', ' . $str . '))), ' .