Try this:
select v1+','+v2+case when v3 = '' then '' else ',' end +coalesce(v3,'')+case when v4 = '' then '' else ',' end +coalesce(v4,'')+case when v5 = '' then '' else ',' end +coalesce(v5,'') veggies, Contar [count] from (
select v1,v2, v3,v4,v5, COUNT(ID) contar from ingredients
group by v1,v2, v3,v4,v5
union
select v1,v2, '' v3,'' v4 ,'' v5, COUNT(ID) contar from ingredients
group by v1,v2
union
select v1,v3, '','','', COUNT(ID) from ingredients
group by v1,v3
union
select v1,v4, '','','', COUNT(ID) from ingredients
group by v1,v4
union
select v1,v5, '','','', COUNT(ID) from ingredients
group by v1,v5
union
select v2,v3, '','','', COUNT(ID) from ingredients
group by v2,v3
union
select v2,v4, '','','', COUNT(ID) from ingredients
group by v2,v4
union
select v2,v5, '','','', COUNT(ID) from ingredients
group by v2,v5
union
select v3,v4, '','','', COUNT(ID) from ingredients
group by v3,v4
union
select v3,v5, '','','', COUNT(ID) from ingredients
group by v3,v5
union
select v4,v5, '','','', COUNT(ID) from ingredients
group by v4,v5
union
select v1,v2, v3,'','', COUNT(ID) from ingredients
group by v1,v2,v3
union
select v1,v2, v4,'','', COUNT(ID) from ingredients
group by v1,v2,v4
union
select v1,v2, v5,'','', COUNT(ID) from ingredients
group by v1,v2,v5
union
select v1,v3, v4,'','', COUNT(ID) from ingredients
group by v1,v3,v4
union
select v1,v3, v5,'','', COUNT(ID) from ingredients
group by v1,v3,v5
union
select v1,v4, v5,'','', COUNT(ID) from ingredients
group by v1,v4,v5
union
select v2,v3, v4,'','', COUNT(ID) from ingredients
group by v2,v3,v4
union
select v2,v3, v5,'','', COUNT(ID) from ingredients
group by v2,v3,v5
union
select v2,v4, v5,'','', COUNT(ID) from ingredients
group by v2,v4,v5
union
select v3,v4, v5,'','', COUNT(ID) from ingredients
group by v3,v4,v5
union
select v1,v2, v3,v4,'', COUNT(ID) from ingredients
group by v1,v2,v3,v4
union
select v1,v2, v3,v5,'', COUNT(ID) from ingredients
group by v1,v2,v3,v5
union
select v1,v2, v4,v5,'', COUNT(ID) from ingredients
group by v1,v2,v4,v5
union
select v1,v3, v4,v5,'', COUNT(ID) from ingredients
group by v1,v3,v4,v5
union
select v2,v3, v4,v5,'', COUNT(ID) from ingredients
group by v2,v3,v4,v5
union
select v1,v2, v3,v4,v5, COUNT(ID) from ingredients
group by v1,v2,v3,v4,v5) AS xxx