Many international carriers fly directly to Hamburg from the main European cities. If you’re flying from US or Canada probably you’d have to go via Frankfurt.
To get into the city take the Airport Express (approx. 5 Euro; every 15 minutes; to Altona, Hauptbahnhof). A taxi to Hamburg takes around 30min and costs approx. 15 euros.
Hamburg has an airport in Fuhlsbüttel which is a quarter of Hamburg. Of course there is a railway station in the centre of the city.