{"categories":[],"published":"2020-12-02 19:32:56","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.kyanny.me%2Fentry%2F2020%2F12%2F02%2F193256\" title=\"PostgreSQL: psql -c \u306e\u7d50\u679c\u3067\u30da\u30fc\u30b8\u30e3\u3092\u7121\u52b9\u306b\u3059\u308b - @kyanny&#39;s blog\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","type":"rich","width":"100%","image_url":null,"url":"https://blog.kyanny.me/entry/2020/12/02/193256","title":"PostgreSQL: psql -c \u306e\u7d50\u679c\u3067\u30da\u30fc\u30b8\u30e3\u3092\u7121\u52b9\u306b\u3059\u308b","description":"1. -P (--pset) \u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u4f7f\u3046 psql -P 'pager=off' -c '\\dp' 2. \u74b0\u5883\u5909\u6570\u3067 PAGER=cat \u3068\u3059\u308b PAGER=cat psql -c '\\dp' \u691c\u8a3c\u624b\u9806 1. \u30b3\u30f3\u30c6\u30ca\u3092\u4f5c\u308b docker run --rm -e 'POSTGRES_HOST_AUTH_METHOD=trust' --name aa -d postgres 2. \u30c6\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u4f5c\u308b for i in {1..100}; do docker exec aa psql -U postgres -c \"create table tt$i (id int)\"; done 3. p\u2026","author_name":"a666666","version":"1.0","blog_url":"https://blog.kyanny.me/","height":"190","blog_title":"@kyanny's blog","author_url":"https://blog.hatena.ne.jp/a666666/","provider_url":"https://hatena.blog","provider_name":"Hatena Blog"}