DO $$ 
    BEGIN
          IF EXISTS (SELECT "Id" FROM public."Versions" WHERE "Build">=1765) THEN
		RETURN;
          END IF;
        BEGIN
           CREATE TABLE public."UserPositions"
(
	"Id" bigserial NOT NULL,
	"UserId" bigint NOT NULL,
	"Position" character varying(64) NOT NULL,
	"ParentUserId" bigint
);
        EXCEPTION
            WHEN duplicate_table THEN RAISE NOTICE 'Create table <UserPositions>.';
        END;
    END;
$$


