You shoot the subject with full bokeh if u wish... then ask him/her to move away (if it's a tree, building, then a diff story), shoot the background in small aperature to get its full glory (HD also can), then merge them together. Otherwise you should get a short wide angle lens.
Think what you're asking is to capture the entire pic clearly? Ans is above, no use zoom...
Software that implemented such algorithm http://www.topazlabs.com/infocus/ It has a fully 30days functional trial. You can try it with no harm done on your this picture that you are trying to restore and see how much you can recover back from it.
But of course, it's way "cheaper" if you just capture it right in focus in the first place