Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qP8o6-00A5br-Fn for pgsql-general@arkaria.postgresql.org; Thu, 27 Jul 2023 21:46:03 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qP8o4-00C22V-M8 for pgsql-general@arkaria.postgresql.org; Thu, 27 Jul 2023 21:46:00 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qP8o3-00C22M-1S for pgsql-general@lists.postgresql.org; Thu, 27 Jul 2023 21:46:00 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qP8nx-000lL0-E3 for pgsql-general@lists.postgresql.org; Thu, 27 Jul 2023 21:45:58 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 209F55C027B; Thu, 27 Jul 2023 17:45:51 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Thu, 27 Jul 2023 17:45:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:content-transfer-encoding:content-type:content-type:date:date :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm2; t= 1690494351; x=1690580751; bh=ZyTKYhB2vy+1bzmeKaC2NjdwTbshs7uU1ho /4yi46gQ=; b=LbtCRv3XSXXtS7P/3rRwBSYO8JQtvwEJ3mw9HWbTWoZZvXAEOaA Hs9wTS3vehchswij3oBLxtS4D+VFfPA/SUs4rBT826oWTgMyAkpQL+E4jKR7jfSj qXQ7saEytKHIYzd2SZEWBkK2vUgkQ6wNtpNnzF7BiCZR4BRU6bPqcCLOgXZPAbgb FgMMm6HKy9LyqLoMW8Q7own04P7PzpsM6PdIj8P96QR9deSlG0yEXjVqhOYqWe9S nu+DAlTzicA7OBW8ROwrx00kv32a42IYXkB0N31I6IOrBd9Z/gNe1l6XEzOEc/vv zFwqUMKenQTK2mDkzLEr2vVB9+XoJm/Cn9g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1690494351; x= 1690580751; bh=ZyTKYhB2vy+1bzmeKaC2NjdwTbshs7uU1ho/4yi46gQ=; b=J dA3qvaVl7A8rNrlYYDyRXx5dmKVMTVi74R6nIXL51laVonkBaqNvrKDKD11ZxxNa 1ztllA7kltybyNZ9XbU0YXwDgBciQsmgmx/gwTx+HBsAvTJ7rnxBW7aov0UzhBO2 aa6kj0uwGuiu7oCsNwqY6rzMbvMlecwgHUhQigQ272T4ikUWbeklguZ3HqnWQGMt /fZXs/Dwpd4AlhDz31rzlES/9X5FGuVId15gwBr9q1ii8S9mC97MpfHaarx5Dgk+ REBz+8TEyRlgnlxdWK5PAdJpeWaVYSCscdcZTrJ532wsKFERzCFFbSFZdTuWNFRG HvDam8NORmJayFHnPo0iQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrieehucetufdoteggodetrfdotffvucfrrh hofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgenuceurghi lhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurh epuffvfhfhkffffgggjggtgfesthekredttdefjeenucfhrhhomheptegurhhirghnucfm lhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhmqeenuc ggtffrrghtthgvrhhnpeduudefjeetveffhefgudehtdfhvdetkeeiueehfeevveduteek leeuheegudehhfenucffohhmrghinhepphhoshhtghhrvghsqhhlrdhorhhgnecuvehluh hsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprggurhhirghnrdhk lhgrvhgvrhesrghklhgrvhgvrhdrtghomh X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 27 Jul 2023 17:45:50 -0400 (EDT) Subject: Re: password error in batch script To: Atul Kumar , pgsql-general References: From: Adrian Klaver Message-ID: Date: Thu, 27 Jul 2023 14:45:48 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 7/27/23 1:17 PM, Atul Kumar wrote: > Hi, > > I have a password Vl=SO*CIz%A83FQF that is working fine like that in the > command prompt but when it is being used in a batch file it is giving me > an error of wrong password, the password is something looks like that in > batch script. > > set "PGPASSWORD=Vl=SO*CIz%A83FQF" More information needed. 1) What sort of batch script; shell, Python, etc? 2) OS and version. 3) What is set pointing at? 4) PGPASSWORD is an environment variable per: https://www.postgresql.org/docs/15/libpq-envars.html So I would expect export PGPASSWORD = . 5) Why not use pgpass?: https://www.postgresql.org/docs/current/libpq-pgpass.html > > Could you please help me in getting this password read by command prompt > in the batch file. > > > > Regards. -- Adrian Klaver adrian.klaver@aklaver.com