Sheikh Ibn Jibreen (may Allah have mercy on him) said:
Praying qiyaam in Ramadan is attained by praying part of the night, such as half of it or one third of it, whether that is by praying eleven rak‘ahs or twenty-three. Qiyaam is attained by praying behind the neighbourhood imam until he finishes, even if he finishes within one hour.
Imam Ahmad (rh) used to pray with the imam and not leave until he finished, acting in accordance with the Hadith. And whoever wants to attain this reward must pray with the imam until he finishes Witr, whether he prays a little or a lot, and whether the time taken is long or short.
Fataawa al-Shaykh Ibn Jibreen.