Exemplo n.º 1
0
        public List <string> GetRawTableDumpLines(PgItem table, bool withPrivileges)
        {
            var tableArg = table.GetTableArg();
            var args     = string.Concat(baseArg, " --schema-only  --no-owner", withPrivileges ? "" : " --no-acl");

            return(GetDumpLines(args, tableArg));
        }
Exemplo n.º 2
0
        private string GetSeqContent(PgItem seq, string args)
        {
            var tableArg = seq.GetTableArg();

            if (settings.DbObjectsRaw)
            {
                return(GetPgDumpContent($"{args} {tableArg}"));
            }
            return(new SequenceDumpTransformer(seq, GetDumpLines(args, tableArg)).BuildLines().ToString());
        }
Exemplo n.º 3
0
        private string GetViewContent(PgItem table, string args)
        {
            var tableArg = table.GetTableArg();

            if (settings.DbObjectsRaw)
            {
                return(GetPgDumpContent($"{args} {tableArg}"));
            }
            return(new ViewDumpTransformer(GetDumpLines(args, tableArg))
                   .BuildLines(dbObjectsCreateOrReplace: settings.DbObjectsCreateOrReplace)
                   .ToString());
        }