The general formula: to be (in the correspondent tense of the Perfect group) + Participial I of the notional verb.
Note: This group only numbers two tenses - Present and Past because the Future Perfect Continuous is not practically used.
The general definition. This group denotes an action, which began in the past (or before a definite moment in the past), has been going on for a certain period of time by the present moment (or had been going on for a certain period of time by that moment) and is still going on now (or was still going on at that moment).
These are the Present and the Past Perfect Continuous Inclusive.
With verbs that are not used in continuous tenses the Present Perfect Continuous and the Past Perfect Continuous are replaced by the Present Perfect Inclusive and Past Perfect Inclusive accordingly.
They have been married for two years.
Они женаты два года.
In the Passive Voice the tenses of the Perfect Continuous group are replaced by the correspondent tenses of the Perfect group (Inclusive).
This question has been discussed for two hours.
This question has been being discussed for two hours.
Этот вопрос обсуждают два часа.
I've been waiting for him for two hours.
Я жду его два часа.
I've been waiting for him since a very morning.
Я жду его с самого утра.
I've been waiting for him since I came to work.
Я жду его с того момента, как я пришел с работы.
This certain period of time can be expressed in two ways - either by an adverbial phrase with the preposition for or by the starting point of the action which, in its turn, can be expressed in two ways - either by an adverbial phrase with the preposition since or by an adverbial clause of time with conjunction since.
He said that he had been working on this program for two months.
Он сказал, что работает над этой программой два месяца.
The Present and the Past Perfect Continuous Exclusive denote an action, which has just been going on before the present moment (or before a definite moment in the past), is not going on now (was not going on at that moment) and is regarded as a process.
I've just been talking to him.
Я только что говорил с ним.
She asked me with whom I had just been talking.
Она спросила меня, с кем я только что разговаривал.
One should bear in mind that adverbial phrases for a long time and how long are regarded as periods.
How long have you been waiting for me?
Сколько ты меня ждешь?
They have been working on this program for a long time.
Он давно работает над этой программой.
Both the Present Perfect and the Present Perfect Continuous can be used with the adverb lately. The latter is used when the action is still going on.
I've seen several interesting films lately.
В последнее время я посмотрел несколько интересных фильмов.
Your son has been doing very badly lately.
Ваш сын в последнее время очень плохо учится.