Aggregation operations are important in WSN applications. Since large numbers of applications only require approximate aggregation results rather than the exact ones, some approximate aggregation algorithms have been proposed to save energy. However, the error bounds of these algorithms are fixed and it is impossible to adjust the error bounds automatically, so they cannot meet the requirement of arbitrary precision required by various users. Thus, a uniform sampling-based algorithm was proposed by the authors of this paper to satisfy arbitrary precision requirement. Unfortunately, this uniform sampling-based algorithm is only suitable for static sensor networks. To overcome the shortcoming of the uniform sampling-based algorithm, this paper proposes four Bernoulli sampling-based and distributed approximate aggregation algorithms to process the snapshot and continuous aggregation queries in dynamic sensor networks. Theoretical analysis and experimental results show that the proposed algorithms have high performance in terms of accuracy and energy consumption.