【问题标题】:pg_restore is take more time in front end [closed]pg_restore 在前端需要更多时间[关闭]
【发布时间】:2013-05-31 06:33:16
【问题描述】:

在我的项目中,我想restore database 在前端 (vb.net 2008)

所以我在前端使用以下代码,但需要更多时间。所以我很调试。我的以下代码正确吗?或者如何resoredatabasepostgresql 9.0

  xProcId = Shell(PSQL.InstPath & "pg_restore.exe -h " & servername & " -p " & Port _
                              & " -U " & superusername & " -d " & dbname& " -c -v " & backupfilepath , AppWinStyle.Hide)
                Process.GetProcessById(xProcId).WaitForExit()

提前致谢

【问题讨论】:

  • “需要更多时间”->“需要太长时间”?好吧,在一个大文件上它会,而且,你在用它的 stdout/stderr 做什么?如果你不隐藏它,它会起作用吗?
  • 我没有使用像 (Stdout/stderr) 先生这样的东西。你能详细说明一下吗?

标签: vb.net postgresql postgresql-9.0


【解决方案1】:

不要使用 -v(详细模式)会加快速度(除非您出于某种原因需要它来打印结果)。

【讨论】:

    猜你喜欢
    • 2014-03-25
    • 2014-08-16
    • 1970-01-01
    • 2021-06-24
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-03-22
    • 1970-01-01
    相关资源
    最近更新 更多