fix problem to connect to postgresql base
useinheritance of template