Retirement tax questions

Thanks for replying- my question was specifically with regards to my state tax obligations. Treating the excessive deferral to have occured from first account means that i am supposed to pay state tax on this amount to my earlier state of residence, while if i treat the second 401k account as excess deferral, it would meanthat i would have to pay state tax to the second state