AC codeshare on LH may dump you in Y if AC doesn't have the codeshare availability. As long as the fare allows to book pure LH (and LH has the availability) then you can book J throughout.
Always call the operating carrier to book seats, though some airline systems don't work well with each other (I think the AC codeshare with LH seat issue has its own FT thread), and could prevent you from selecting seats altogether.