I dont know if it was possible when this question came up 5 years ago but I know that nowadays its possible throught the field calculator :