How long have you been (doing something)?

This is a question that you can ask someone about an activity that they still do:

How long have you been practicing Judo?

How long have you been waiting here?

If someone no longer does something, you should ask a different question:

How long did you work at IBM?

By the way, if you want to be extra formal and grammatically correct, you can as "For how long...?"  For example, you might hear this in a legal court:

For how long were you and the defendant involved romantically?

This phrase appears in these lessons: