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 1jj53P-0001pj-CF for pgsql-general@arkaria.postgresql.org; Wed, 10 Jun 2020 18:02:23 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jj53O-0005Hy-9C for pgsql-general@arkaria.postgresql.org; Wed, 10 Jun 2020 18:02:22 +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 1jj53M-0005Hr-BT for pgsql-general@lists.postgresql.org; Wed, 10 Jun 2020 18:02:22 +0000 Received: from wout4-smtp.messagingengine.com ([64.147.123.20]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jj4mB-0004z7-0j for pgsql-general@lists.postgresql.org; Wed, 10 Jun 2020 17:44:37 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 6B99E760; Wed, 10 Jun 2020 13:44:33 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Wed, 10 Jun 2020 13:44:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:cc:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm3; bh=v i4gL4nkizIvbNWuldxTjKuaID7kQIZuY7RM4Dw4mgY=; b=KhiAS66OxxZHvhxIJ +3ITQUYJItjsa92VfZTTaMDrKygD3PCik/sTwBvMW7o9I3Zbr5MYZR1e9rATnSYu YCabG6KNSWJQpTa6vBNsgmnkrR5xRMFdLH7TykCibxIMCmQUfoY9zrMWBlBojoG4 w3MRdt589NUAgDBAIfW3JTRmCD9haL1nn2pXD8Lcv+PD8F1RqPCaNs8fchqXA2TI 0E/JS9a9ESjrLKTW/q+TJzULN5pilXPKRH6KKr8u2Bt8XJb3uMLGssawBxcfAPV/ 7ej67ov7iBBQIj4kmP5ah4kbL0dUMIpyJ4TgiOc8Mb1WB/LmpiH/fdZGwKzf2vLk ctrxg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=vi4gL4nkizIvbNWuldxTjKuaID7kQIZuY7RM4Dw4m gY=; b=rcmM8BdJZR25a01SVF5McLOzfW+p3W2dmrTbN5QuPKWhvda1teNH/5oha HwXx7PGxbvAZJ7YO01BBvN046yugviEeWMthFtNFZLA7mwWtXasUsUcmLxYc2jK9 HqEQtd+X0sf7f96bPFpmeA00Ku4oDZK51qAJA0pURlTzLAFWBwk4kl+j8oQLrlJa izkh19P/e5055X17N9lYCgmK8FXyOrRNd2aoFRlrl9MvjZwjjQreWxOzf18EEZ68 YCjbjQOa1+kHycn2lYDqALSlpv8vATa7uyQDBsZgQr6Z+BHjYh8utap9OY3nFIbE Fstoe6muvb5UDuTeBGhcv0SlGOGkQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudehiedguddulecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefuvfhfhffkffgfgggjtgfgsehtkeertddtfeejnecuhfhrohhmpeetughr ihgrnhcumfhlrghvvghruceorggurhhirghnrdhklhgrvhgvrhesrghklhgrvhgvrhdrtg homheqnecuggftrfgrthhtvghrnhephfeukeeffeejfefgieeiteeihfeklefhheejffdv keejtddufeetgeekffeuhfetnecuffhomhgrihhnpegrnhgrtghonhgurgdrtghomhdprg hnrggtohhnuggrrdhorhhgpdgvnhhtvghrphhrihhsvggusgdrtghomhenucfkphephedt rdduleejrdektddrvdenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrih hlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhm X-ME-Proxy: Received: from ranger.suse (50-197-80-2-static.hfc.comcastbusiness.net [50.197.80.2]) by mail.messagingengine.com (Postfix) with ESMTPA id 202F4328005D; Wed, 10 Jun 2020 13:44:32 -0400 (EDT) Subject: Re: Help with plpython3u To: PEDRO PABLO SEVERIN HONORATO Cc: pgsql-general@lists.postgresql.org References: <630c303b-1c82-90dc-b602-54e461335fc6@aklaver.com> <13c85ed6-43ae-76e3-058d-97ccc435e96f@aklaver.com> <36efd504-84ac-6190-0d63-a95ffe855c56@aklaver.com> From: Adrian Klaver Message-ID: Date: Wed, 10 Jun 2020 10:44:31 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.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: Precedence: bulk On 6/10/20 10:39 AM, PEDRO PABLO SEVERIN HONORATO wrote: > I'm sorry, when I try to create a plpython3u function, the database > tells me: > > "*ERROR: could not load library "C:/Program > Files/PostgreSQL/12/lib/plpython3.dll": The specified module could not > be found. SQL state: 58P01*" > > If I try to execute the function, then the database crashes. Alright I'm going to have to review where we are at. That will not happen for a bit, so hang on. > > El mié., 10 jun. 2020 a las 13:36, PEDRO PABLO SEVERIN HONORATO > (>) escribió: > > I just think it would make your life easier to reduce the number of > Python installs you have. If I'm keeping track correctly you now have: > > 1) Anaconda Python > > 2) OS system Python > > 3) EDB Python. > > The OS is windows, and afaik python is not included in windows, so > it would be just Anaconda python and EDB python. > > What happens if you try to create a plpythonu3u function in the > database? > > The database crashes and tells me "*Connection to the server has > been lost.*" > > El mié., 10 jun. 2020 a las 13:12, Adrian Klaver > (>) > escribió: > > On 6/10/20 9:57 AM, PEDRO PABLO SEVERIN HONORATO wrote: > > Alright. Before we go any further it would be best to > determine what > > your needs are. So: > > > > 1) Did you install Anaconda just to get Python or for the > science data > > set of libraries it provides? > > > > A: For the data science set of libraries. Also, it helps to keep > > libraries updated. > > > > 2) Do you need the system Python you installed for anything that > > Anaconda does not provide? > > > > A: I don't know if I understood well this question, but I > think the > > answer is no. Anaconda does provide almost all the libraries > I need. I > > just installed a couple more (like talib, tensorflow, keras, > psycopg2, > > etc) and created some libraries of my own. > > Those libraries are available from Anaconda: > > https://docs.anaconda.com/anaconda/packages/py3.7_win-64/ > > or from AnacondaCloud: > > https://anaconda.org/ > > I just think it would make your life easier to reduce the number of > Python installs you have. If I'm keeping track correctly you now > have: > > 1) Anaconda Python > > 2) OS system Python > > 3) EDB Python. > > > What happens if you try to create a plpythonu3u function in the > database? > > > > > > 3) What are you planning to do with plpython3u? > > > > A: I'm planning to create some functions using python > language to > > process data that is stored in real time in the database and > then use > > them as triggers. I would like to be able to import some > libraries that > > I have in python to do it. Some of the functions are fourier > and wavelet > > transforms. If I can't import the library, then I'll have to > code the > > full function, but it's easier (for me) to code them in > python language > > rather than sql language. > > > > El mié., 10 jun. 2020 a las 12:17, Adrian Klaver > > ( > >>) escribió: > > > >     On 6/10/20 8:25 AM, PEDRO PABLO SEVERIN HONORATO wrote: > >      > Just to be clear those where instructions from here, > correct?: > >      > > >      > > > > https://www.enterprisedb.com/edb-docs/d/edb-postgres-advanced-server/user-guides/language-pack-guide/12/EDB_Postgres_Language_Pack_Guide.1.08.html# > >      > > >      > Yes. When I did that I could execute python functions > and create the > >      > extension in postgres without problem, but later I > realized that > >     doing > >      > this will create the other problem with anaconda. > >      > > >      > So when you did the Anaconda install: > >      > > >      > https://docs.anaconda.com/anaconda/install/windows/ > >      > > >      > What did you check for the Advanced options in Step 8? > >      > > >      > I left the first one unchecked and the second one > checked, which > >     is the > >      > default settings. > >      > > > > >     Alright. Before we go any further it would be best to > determine what > >     your needs are. So: > > > >     1) Did you install Anaconda just to get Python or for the > science data > >     set of libraries it provides? > > > >     2) Do you need the system Python you installed for > anything that > >     Anaconda does not provide? > > > >     3) What are you planning to do with plpython3u? > > > > > >     -- > >     Adrian Klaver > > adrian.klaver@aklaver.com > > > > > > > -- > Adrian Klaver > adrian.klaver@aklaver.com > -- Adrian Klaver adrian.klaver@aklaver.com