nerdexam
Splunk

SPLK-1001 · Question #166

Which command will rename action to Customer Action?

The correct answer is D. | rename action as "Customer Action". Option D is correct because Splunk SPL's rename command requires the keyword as to map old names to new names, and the original field name action must match exactly - SPL field names are case-sensitive, so lowercase action is required. The new name "Customer Action" must be…

Question

Which command will rename action to Customer Action?

Options

  • A| rename action = CustomerAction
  • B| rename Action as "Customer Action"
  • C| rename Action to "Customer Action"
  • D| rename action as "Customer Action"

How the community answered

(25 responses)
  • A
    16% (4)
  • B
    4% (1)
  • C
    8% (2)
  • D
    72% (18)

Explanation

Option D is correct because Splunk SPL's rename command requires the keyword as to map old names to new names, and the original field name action must match exactly - SPL field names are case-sensitive, so lowercase action is required. The new name "Customer Action" must be quoted because it contains a space.

  • A fails on two counts: it uses = instead of as, and CustomerAction is missing the space (and quotes) that the target name requires.
  • B uses as correctly and quotes the new name, but capitalizes Action - this won't match the lowercase field action due to case sensitivity.
  • C uses the wrong keyword to instead of as, and also capitalizes Action incorrectly.

Memory tip: Think of SPL rename like an alias in plain English - "rename this as that" - and remember that SPL field names are case-sensitive, so copy the field name exactly as it appears.

Community Discussion

No community discussion yet for this question.

Full SPLK-1001 Practice