V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
sjmcefc2
V2EX  ›  程序员

cur.execute(copy mytalbe from test.txt delimiter '|')这个怎么看执行的状态呢?

  •  
  •   sjmcefc2 · May 5, 2018 · 1507 views
    This topic created in 2913 days ago, the information mentioned may be changed or developed.

    使用 psycopg2 包链接 postgres, 执行 cur.execute(copy mytalbe from test.txt delimiter '|')发现用 cur.fetchall/one()得不到执行的状态。 在终端单独执行 copy,至少能得到一个 copy 行数或者出错信息哈。 请教一下这个怎么获取状态和结果。

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5238 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 33ms · UTC 01:16 · PVG 09:16 · LAX 18:16 · JFK 21:16
    ♥ Do have faith in what you're doing.