14.03.2014 Views

Scripting Guide - SAS

Scripting Guide - SAS

Scripting Guide - SAS

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

100 JSL Building Blocks Chapter 5<br />

Name Resolution<br />

Preventing Column Name and Variable Name Conflicts<br />

When you run a script that includes a column and variable with the same name, an Invalid Row Number<br />

error occurs. To prevent this problem, use unique column and variable names, or scope the names as<br />

follows:<br />

• In this example, age is both a global variable and column name. On line one, age is scoped as a global<br />

variable name (shown here with the :: operator). Now that the global variable exists, only the column<br />

name age needs to be scoped on line two.<br />

::age = [];<br />

age = :age

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!