You can take a train from downtown Barcelona (Sants train station) to Pamplona with RENFE (
www.renfe.com). Alternatively, you can take a bus from downtown Barcelona to Pamplona with
www.monbus.es (Barcelona Sants is easier to reach from the airport than Barcelona Nord). Once in Pamplona, Alsa (
www.alsa.es/en) has seasonal bus service to SJPP. In order to reach Sants from the airport, the Cercanías train service would be the easiest. I don't know the arrival terminal of your flight but you may need to change terminals to take the Cercanías train. Alternatively, you can get the aerobús (
www.aerobusbcn.com) from the airport to the downtown, get off at Plaça Espanya and walk from there till Sants (ask for directions once on the ground).