We follow the stack-baaed approach to query languages which is a new formal and intellectual paradigm for integrating querying and programming for object-oriented databases. Queries are considered generalized programing expressions which may be used within macroscopic imperative statements, such as creating, updating, inserting, and deleting data objects. Queries may be also used as procedures’ parameters, as well as determine the output from functional procedures (SQL-like views). The semantics, including generalized query operators (selection, projection, navigation, join, quantifiers, etc.), is defined in terms of operations on two stacks. The environment stack deals with the scope control and binding names. The result stack stores intermediate and final query results. We discuss definitions of object-oriented concepts and present variants of parameter passing methods. Finally, we indicate a potential of the approach for query optimization based on rewriting.