nerdexam
Oracle

1Z0-497 · Question #126

What do the regexp_pattern and regexp_replace_string parameters accomplish?

The correct answer is A. They find a pattern of nine digits; break the digits into three groups that contain the first three, the. A string search pattern (that is, the values to search for), such as: regexp_pattern => '(.+)@(.+\.[A-Za-z]{2,4})' This setting looks for a pattern of the following form: one_or_more_characters@one_or_more_characters.2- 4_characters_in_range_A-Z_or_a-z - A replacement string…

Oracle Database 12c Architecture

Question

What do the regexp_pattern and regexp_replace_string parameters accomplish?

Exhibit

1Z0-497 question #126 exhibit

Options

  • AThey find a pattern of nine digits; break the digits into three groups that contain the first three, the
  • BThey find a pattern of six digits; break the digits into two groups that contain the first five, and then
  • CThey find a pattern of nine digits and display the digits as XXXXX XX XXXX.
  • DThey find a pattern of nine digits and display the first five digits as XXXXX and the last four digits as

How the community answered

(28 responses)
  • A
    75% (21)
  • B
    4% (1)
  • C
    7% (2)
  • D
    14% (4)

Explanation

  • A string search pattern (that is, the values to search for), such as: regexp_pattern => '(.+)@(.+.[A-Za-z]{2,4})' This setting looks for a pattern of the following form: one_or_more_characters@one_or_more_characters.2- 4_characters_in_range_A-Z_or_a-z - A replacement string, which replaces the value matched by the regexp_pattern setting. The replacement string can include back references to sub-expressions of the main regular expression pattern. The following example replaces the data before the @ symbol (from the regexp_pattern setting) with the text [redacted]. The \2 setting refers to the second match group, which is (.+.[A-Za-z]{2,4}) from the regexp_pattern setting. regexp_replace_string => '[redacted]@\2' - The starting position for the string search string, such as the first character of the data, such as: regexp_position => DBMS_REDACT.RE_BEGINNING - The kind of search and replace operation to perform, such as the first occurrence, every fifth occurrence, or all of the occurrences, such as: regexp_occurrence => DBMS_REDACT.RE_ALL - The default matching behavior for the search and replace operation, such as whether the search is case-sensitive (i sets it to be not case-sensitive): regexp_match_parameter => 'i

Topics

#REGEXP_REPLACE#regular expressions#pattern matching#SQL functions

Community Discussion

No community discussion yet for this question.

Full 1Z0-497 Practice