workign version with Guids