fixed service view query filter; improved service and environment casting to unicode

fixed service view query filter; improved service and environment casting to unicode