Scalar. Returns a given string with every instance of a specified substring replaced with another specified string.
The following example uses the REPLACE function to substitute the result of multiplying the values of two columns, converted to a string, for a square bracketed x in the filledOrder column:
INSERT INTO OutStream SELECT REPLACE(Transaction.filledOrder, '[x]', TO_STRING(InStock.price*InStock.quantity) ) FROM Orders, InStock;