KNOWLEDGE BASE

Unexpected Type Error When Using SCRIPT_REAL


Published: 11 Nov 2020
Last Modified Date: 12 Nov 2020

Issue

When passing NA from RServe to the SCRIPT_REAL function, an "Unexpected Type" error appears

Environment

  • Tableau Desktop 2019.4-2020.4

Resolution

This issue does not affect SCRIPT_STR. Therefore, as a possible workaround until Tableau Desktop 2021.1 is available, use SCRIPT_STR instead of SCRIPT_REAL, and cast the results as a FLOAT.
 

Cause

NA is a special type of null. Prior to Tableau Desktop 2019.4, NA was converted to NULL in Tableau when passed to SCRIPT_REAL.
This is a known issue that is being addressed by development team.
 
Did this article resolve the issue?