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 1rwAYn-00HLQi-Mq for pgsql-general@arkaria.postgresql.org; Mon, 15 Apr 2024 00:51:02 +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 1rwAYl-0097dV-3I for pgsql-general@arkaria.postgresql.org; Mon, 15 Apr 2024 00:50:59 +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 1rwAYj-0097dN-9z for pgsql-general@lists.postgresql.org; Mon, 15 Apr 2024 00:50:58 +0000 Received: from fout3-smtp.messagingengine.com ([103.168.172.146]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rwAYb-000yb6-Mb for pgsql-general@postgresql.org; Mon, 15 Apr 2024 00:50:56 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailfout.nyi.internal (Postfix) with ESMTP id 005E41380084; Sun, 14 Apr 2024 20:50:48 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Sun, 14 Apr 2024 20:50:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc: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:subject:subject:to:to; s=fm1; t=1713142247; x=1713228647; bh=SLml5qdXzZjQQ0EubTzFTYXN+U86p7MxX9zXCN2EZcA=; b= GSi3a4FJUNQmnjz8GOXi1J88B2CMLFBsHARMwLC47/sm6BwUUvnahorQMRqAwKQm er2dwcfER4lR1PNQLGThPyN2rTCcEjU4OLgs/kQbFsewhINGOFn10pAkhI3Q71Jd FetMsjIwiKU5VY+H8A0hgLg3+Hn9QDJn5faKWRyjoV7SXUQvrXoBeVYStJzw97cM Es378+yKc0UbKBXrQnBsScoxtpeLMY44W/tmhp0v9U3hbWOxjndvovWeAAdXpWKn aV2OcedNXYIykf1DLyh+4IU36C8k2P5KpzdIG+gW6blmiy18uWXWv5jL+9YS3Iq5 RCT8BA97jIuO95saH44AzA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc: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:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1713142247; x= 1713228647; bh=SLml5qdXzZjQQ0EubTzFTYXN+U86p7MxX9zXCN2EZcA=; b=Z Sv7R0+a8C2oFSIdlavHijcRjWRoqIQc8xI1dtYkFkEi8iZY73fdfx3tVpnnPM0TP 6KeYQrj40OubwRLfkhq87WtT5CeSbKmv6MC2eKRtTV8U1iSKhSoZqmOiiXJvzPVu oySHZrITofZqij/1mQFJDnw1sFEvrQ45LZ/ZnyOfZRUtGuL50SqXrGUshcEYJaRl bmSvHLvGkOU7fVfij3uQrxI1LqNBplMMT57g1iHWkHvBop9QjP8Bj9ZQjiAuhofa v2zuSjxRpA/tJBftPlqgswIHglSCyufr0B8EGYiDWavDD/fhg2JXCv3PRnTxcncY No2d54tM5BIaUNTRBev7A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrudejtddgudegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefkffggfgfuvfhfhfevjggtgfesth ejredttddvjeenucfhrhhomheptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdr khhlrghvvghrsegrkhhlrghvvghrrdgtohhmqeenucggtffrrghtthgvrhhnpedtkeelue efieekvedttedutdejfeffvdehffevkeevveevgfeggeeluedukeegieenucevlhhushht vghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrughrihgrnhdrkhhlrg hvvghrsegrkhhlrghvvghrrdgtohhm X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 14 Apr 2024 20:50:47 -0400 (EDT) Message-ID: <22563b64-de45-4131-b6b1-8498abb6c718@aklaver.com> Date: Sun, 14 Apr 2024 17:50:46 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: constant crashing To: jack References: <311b047d-01f1-4ce3-86de-09ff0181ba00@aklaver.com> Content-Language: en-US From: Adrian Klaver Cc: pgsql-general In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 4/14/24 14:50, jack wrote: Reply to list also Ccing list > Hello, > I am not sure what "locale" means. Go to the settings App for whatever version of Windows you are on and search for locale. > The Windows app is an inhouse application which uses Actian-Zen SQL. > The data is exported to simple ASCII in a tab delimited format similar to CSV. And you know it is ASCII for a fact? > Those files are then imported into the PostgreSQL table using COPY. > Importing the data is not an issue. > I am able to load all the data without any problems, even into 1 table which ends up with about 1.2 billion records. > But when I try to update the data in that table I get many errors, essentially crashes. Repeating what has been asked and answered it not really going anywhere. > There may be some control characters (garbage) in the data but that should not crash postgresql, especially if it can import the data without issues. Unless it does. That is the point of the questions, getting to what is actually causing the issue. Until the problem can be boiled down to a reproducible test case there really is not much hope of anything more then the the 'yes you have a problem' answer. And there is a difference between dumping data into a table and then doing an UPGRADE where the data strings are manipulated by functions. > Anyway, I hope I answered your questions. > Thanks for your help. > > > > On Sunday, April 14th, 2024 at 4:28 PM, Adrian Klaver wrote: > >> >> >> On 4/14/24 13:18, jack wrote: >> >>> The CSV files are being produced by another system, a WIndows app on a >>> Windows machine. I then copy them to a USB key and copy them onto the >>> ubuntu machine. The data is then imported via the COPY command. >> >> >> The app? >> >> The locale in use on the Windows machine? >> >> The locale in use in the database? >> >>> COPY master (field01,field02..fieldX) FROM '/data/file.text' DELIMITER E'\t' >>> The fields are tab delimited. >>> >>> But importing the data works. I can get all the data into a single table >>> without any problems. The issue is only when I start to update the >>> single table. And that is why I started using smaller temporary tables >>> for each CSV file, to do the updates in the smaller tables before I move >>> them all to a single large table. >> >> >> The import is just dumping the data in, my suspicion is the problem is >> related to using string functions on the data. >> >>> After all the data is loaded and updated, I run php programs on the >>> large table to generate reports. All of which works well EXCEPT for >>> performing the updates on the data. And I do not want to use perl or any >>> outside tool. I want it all one in SQL because I am required to document >>> all my steps so that someone else can take over, so everything needs to >>> be as simple as possible. >> >> >> -- >> Adrian Klaver >> adrian.klaver@aklaver.com -- Adrian Klaver adrian.klaver@aklaver.com