You asked
Is the pentax smc da 14mm f 2 8 ed if good for astrophotography?
The site doesn't cover astrophotography directly, so it can't confirm how this lens performs at night. It does give the facts that matter most for a night-sky shot. At f/2.8 the lens gathers well over three stops more light than a f/5.6 lens, which helps when the sky is dim. At 14mm it is wide, and on an APS-C Pentax K body it frames like 21mm on full frame, so it takes in a broad sweep of sky. The main thing it gives up is stabilisation: this lens has none, so you'll rely on a stable tripod and your exposure settings rather than the lens to keep the image steady.
The camera body matters as much as the lens. The guide says a larger sensor and a fast lens matter more than stabilisation in dim light, so the Pentax K-1 Mark II is the strongest pairing for this lens on this page. It is full frame, but with this lens it works in APS-C crop mode at fewer megapixels. If you want an APS-C body, the Pentax KP and the Pentax K-3 Mark III both fit this lens and are the newer APS-C options listed for it. The page doesn't say how any of these handle noise or star trails, so check those in reviews before buying.
For the basics of how aperture affects light, see the aperture section of the lenses guide.
Written by Claude from this site's pages.
From these pages
This answer is for the question above. Each answer is written for the exact question in its address, so a question with its details in it (a budget, what you shoot, what you already have) gets an answer about those details. An answer draws on all 15 pages of the guide and its catalogue of 320 cameras and 1050 lenses. Another question gets its own answer at its own address, as words after /ask/. Or fill in your own: /ask/which-camera-for-{what-you-shoot}-under-{budget}-euros or /ask/which-lens-for-{what-you-shoot}-on-{your-camera}.