SPLK-1002 Exam QuestionsBrowse all questions from this exam

SPLK-1002 Exam - Question 104


Given the following eval statement:

... | eval field1 = if(isnotnull(fieid1),field1,0), field2 = if(isnull

Which of the following is the equivalent using fillnull?

Show Answer
Correct Answer: A

The given eval statement checks if 'field1' is not null and assigns it to 'field1' or assigns 0 if it is null, and it checks if 'field2' is null and assigns 'no-value' or keeps 'field2' otherwise. The 'fillnull' command is used to replace null values in specified fields with specified values. However, the logic in the eval statement includes conditions that cannot be directly translated to a fillnull command, especially with mixed data types and specific conditions on multiple fields. Therefore, there is no equivalent expression using 'fillnull'.

Discussion

5 comments
Sign in to comment
Amish0123Option: C
Feb 4, 2023

Tested .. Answer is C

poubellelc66
Jun 19, 2023

C can't work as there is a ' after the pipe that is not closed

cansu91Option: A
Feb 6, 2023

What ist the right answer? I selected A but I'm not sure.

NetworkingGuy2Option: A
May 19, 2023

I would say probably A, the current search is probably meant to be: | eval field1 = if(isnotnull(fieid1),field1,0), field2 = if(isnull,field2, "NO VALUE") Thus, the first part which is asking if field1 isnotnull eg 104, then make that value 0. Points me to A, as no fillnull command or option here can do this step.

Dree_DoggOption: A
Aug 16, 2023

I'd go with A. The question has a bad eval statement.

The_LuciferOption: D
Jan 29, 2024

why not D?