The paper considers a pair consisting of an optimization problem and its optimality function (P,θ), and defines consistency of approximating problem-optimality function pairs, (PN,θN) to (P,θ), in terms of the epigraphical convergence of the PN to P, and the hypographical convergence of the optimality functions θN to θ. It then shows that standard discretization techniques decompose semi-infinite optimization and optimal control problems into families of finite dimensional problems, which, together with associated optimality functions, are consistent discretizations to the original problems. The paper then presents two types of techniques for using consistent approximations in obtaining an approximate solution of the original problems. The first is a ‘filter’ type technique, similar to that used in conjunction with penalty functions, the second one is an adaptive discretization technique that can be viewed as an implementation of a conceptual algorithm for solving the original problems.