You might think of a SAS dataset as if it were a Excel spreadsheet.
The variable names are the column names (and actually they are not that easy to rename) - an observation (record) is a line in the spreadsheet. A cell contains the value of a distinct variable ( a "column") at a specific point of iterating through the dataset.
That's what a datastep mainly does. It iterates through the "lines of the spreadsheet", from top to bottom, one line at a time between the "data" statement and the "run" statement.
So what you're asking for - changing the value of a variable (a cell value) - is the most basic thing you can do in SAS.
Let's assume the following:
/* write ten observations (records) to table have with one column (variable) "myvar" */
do myvar=1 to 10;
if myvar=5 then myvar=999;
proc print data=myvar;
xij could be regard as the value of the variable, it is string type, so, to some extent, revise it is just as change the value of a variable , think about if xij is a numerical value, how would you revise it, the technique is much the same, but maybe you have to use some function and special operator , since you may have to combine the string.
It seems to me that you want to treat the entire dataset as though it is an array, like this:
o1 x11 x12
o2 x21 x22
as though x(i,j) is a value that you can derive positionally from the "row" order in the dataset and the column order.
However, if the data were sorted in DESCENDING order by V1, then your dataset would look like this:
o1 x21 x22
o2 x11 x12
where the "row" order no longer would correspond to the x(i,j). The SAS observation numbers or row numbers are not "fixed"...they do not stay in the file. They only appear on reports like PROC PRINT and PROC UNIVARIATE in order to help you locate rows. The observation number can and will change depending on the sort order of the file, whether you have deleted any observations, etc.