Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 63176 invoked from network); 11 Apr 2008 13:56:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Apr 2008 13:56:37 -0000 Received: (qmail 40384 invoked by uid 500); 11 Apr 2008 13:56:36 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 40359 invoked by uid 500); 11 Apr 2008 13:56:36 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 40347 invoked by uid 99); 11 Apr 2008 13:56:36 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Apr 2008 06:56:36 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [81.228.8.164] (HELO pne-smtpout2-sn2.hy.skanova.net) (81.228.8.164) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Apr 2008 13:55:53 +0000 Received: from W193MTEC (213.67.144.50) by pne-smtpout2-sn2.hy.skanova.net (7.3.129) id 47A02DB90183E6C3 for derby-user@db.apache.org; Fri, 11 Apr 2008 15:56:05 +0200 Message-ID: <00b301c89bdb$9eacffa0$6401a8c0@emea.itt.net> From: "Mikael" To: "Derby Discussion" References: <009701c89bda$316222f0$6401a8c0@emea.itt.net> Subject: Re: Problems with BLOBS (fixed....) Date: Fri, 11 Apr 2008 15:54:53 +0200 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 X-Virus-Checked: Checked by ClamAV on apache.org Sorry about that, my head was in Mississippi or something, I managed to use an old Derby jar file so I was not running the correct version, sorry. Mikael ----- Original Message ----- From: "Mikael" To: "Derby Discussion" Sent: Friday, April 11, 2008 3:44 PM Subject: Problems with BLOBS > Hi ! > > About a year ago I ahd som problems with BLOBS in Derby because of bugs, I > gave up at that time but I thought I kight give it another try and see if > it works any better today, but no luck at all so far, there was some very > helpful people here trying to fix it and as far as I remember the problem > wad found... ? > > I am trying to put a 56721 byte file into a record with a BLOB field (16M > limit). > > byte[] data = > ByteArrayInputStream is = new ByteArrayInputStream( data); > String sql = "UPDATE USF.FileSystem SET FTimeSrc='" + fdateFile + > "',FTime='" + fdate + "',FContents=? WHERE FName='" + name + "'"; > PreparedStatement ps = conn.prepareStatement( sql); > ps.setBinaryStream( 1, is, data.length); > > if( ps.executeUpdate() == 0) // Check if record already exists, if not > do an INSERT > { > } > > But it crashes at the ps.executeUpdate call (it works fine with smaller > files though). > ----------------------------------------------------------------------------------------- > org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because > of a Distributed Protocol Error: DRDA_Proto_SYNTAXRM; CODPNT arg = 0; > Error Code Value = 3. Plaintext connection attempt from an SSL enabled > client? > at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(Unknown > Source) > at org.apache.derby.impl.drda.DDMReader.readDssHeader(Unknown > Source) > at > org.apache.derby.impl.drda.DRDAConnThread.processCommands(Unknown Source) > at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source) > org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because > of a Distributed Protocol Error: DRDA_Proto_SYNTAXRM; CODPNT arg = 0; > Error Code Value = 3. Plaintext connection attempt from an SSL enabled > client? > at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(Unknown > Source) > at org.apache.derby.impl.drda.DDMReader.readDssHeader(Unknown > Source) > at > org.apache.derby.impl.drda.DRDAConnThread.processCommands(Unknown Source) > at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source) > ----------------------------------------------------------------------------------------- > > The table I am using look's like this: > "CREATE TABLE USF.FileSystem (\n" + > "FTime timestamp NOT NULL,\n" + // Date for uploading > "FTimeSrc timestamp NOT NULL,\n" + // Time stamp for original > file > "FContents BLOB(16M) NOT NULL,\n" + // The contents of the file > "FName varchar(300) NOT NULL)"; // Name of file > > Any ideas why this isn't working ? > > My original problem was as follows: > ------------------------------------ > [ > https://issues.apache.org/jira/browse/DERBY-3085?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] > > Kathey Marsden updated DERBY-3085: > ---------------------------------- > > Derby Info: [Patch Available, Regression] (was: [Regression]) > > Tests passed except for demo/checkToursDB which I don't think could be > related as it is not network server related. > > Please review patch derby-3085_diff.txt > > Not sure if this is related to the problem this time though.... but the > exceptions look about the same. > > Mikael >