The best way to get architectures in the image in focus, is to keep the aperture less wide open. That is around f/8, f/11 or sometimes above than these, are good for architecture photography at day time or sunny days. While, in nighttime architecture photography, basically a long exposure method is applied keeping the f-stop in between f/5.6 and f/8.