added in some functionality for AND, OR, PIPE