Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1neb0j-0000UK-7M for pgsql-performance@arkaria.postgresql.org; Wed, 13 Apr 2022 11:18:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1neb0i-0000Ya-15 for pgsql-performance@arkaria.postgresql.org; Wed, 13 Apr 2022 11:18:08 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1neb0h-0000X1-O6 for pgsql-performance@lists.postgresql.org; Wed, 13 Apr 2022 11:18:07 +0000 Received: from relay2-d.mail.gandi.net ([217.70.183.194]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1neb0e-0007NH-Ln for pgsql-performance@postgresql.org; Wed, 13 Apr 2022 11:18:06 +0000 Received: from localhost (pc-164-217-214-201.cm.vtr.net [201.214.217.164]) (Authenticated sender: andrew@acooke.org) by mail.gandi.net (Postfix) with ESMTPA id 5330D40010; Wed, 13 Apr 2022 11:17:59 +0000 (UTC) Received: from localhost (localhost [IPv6:::1]) by localhost (Postfix) with ESMTP id 5652523D16A; Wed, 13 Apr 2022 07:17:56 -0400 (-04) Date: Wed, 13 Apr 2022 07:17:56 -0400 From: andrew cooke To: Laurenz Albe Cc: "Kumar, Mukesh" , "pgsql-performance@postgresql.org" , MUKESH KUMAR Subject: Re: Performance for SQL queries on Azure PostgreSQL PaaS instance Message-ID: <20220413111756.niehtkrpcv4ptf2h@acooke.org> References: <4ae8501377e4ba5155cfee5e6eaca3fe674f7f98.camel@cybertec.at> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <4ae8501377e4ba5155cfee5e6eaca3fe674f7f98.camel@cybertec.at> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Apr 13, 2022 at 10:34:24AM +0200, Laurenz Albe wrote: > On Tue, 2022-04-12 at 09:10 +0000, Kumar, Mukesh wrote: > > We have recently done the migration from Oracle Database Version 12C to Azure > > PostgreSQL PaaS instance version 11.4 and most of the application functionality > > testing has been over and tested successfully > >   > > However, there is 1 process at application level which is taking approx. 10 mins > > in PostgreSQL and in oracle it is taking only 3 mins. > >   > > After investigating further we identified that process which is executed from > > application end contains 500 to 600 no of short SQL queries into the database. > > We tried to run the few queries individually on database and they are taking > > less than sec in Postgres Database to execute, and we noticed that in Oracle > > taking half of the time as is taking in PostgreSQL. for ex . in oracle same > > select statement is taking 300 millisecond and in PostgreSQL it is taking > > approx. 600 millisecond which over increases the execution of the process. > >   > > Oracle Database are hosted on ON- Prem DC with dedicated application server on > > OnPrem and same for PostgreSQL. > > How can a database hosted with Microsoft be on your permises? Not OP, but it couldn't it be https://azure.microsoft.com/en-us/overview/azure-stack/ ? > Apart from all other things, compare the network latency. If a single request > results in 500 database queries, you will be paying 1000 times the network > latency per request. > > Yours, > Laurenz Albe > -- > Cybertec | https://www.cybertec-postgresql.com > > >