db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Satheesh Bandaram <sathe...@Sourcery.Org>
Subject Re: Error when running a delete all a 2nd time
Date Tue, 16 Aug 2005 17:19:22 GMT
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
I think Army has already answered this question...Since there is a
primary key on the column, Derby would have created an unique index on
it, so attempting to create another unique index on the same column
would raise the warning. Why it is a warning and not an error, I don't
know <span class="moz-smiley-s1"><span> :-)&nbsp; </span></span>(since
it
doesn't actually create the second index...)<br>
<br>
So your first problem is not related to this one...<br>
<br>
Satheesh<br>
<br>
Peart, David E. wrote:
<blockquote
 cite="mid8FA12926CCB8EC4CB47333C9B65F95D3015EDF03@EMAIL.atpiad1.local"
 type="cite">
  <title></title>
  <meta http-equiv="Content-Type" content="text/html; ">
  <meta content="MSHTML 6.00.2900.2523" name="GENERATOR">
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Satheesh</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">when you say a complete
reproduction you mean all code, etc?</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Anyway, I'm also getting this
error on creating indexes, may be it is related.&nbsp; So I'd like to see if
this was resolved then see if the other problem goes away.</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">The problem is:</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">WARNING 01504: The new index is
a duplicate of an existing index: SQL050816084652910.</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">But its not a duplicate.&nbsp; It
creates this warning on the 2nd index PARGRP.X2FTNRC2</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Additionally, although its a
warning it does not create the 2nd index !!!!!&nbsp; I checked the system
tables for which indexes are created.</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Let me know if you need the ddl
on the table again, and may be you can try creating the table with the
three indexes and see if you get the same error.</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Note: we are loading the tables
onto DB2 and have no issues there.</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">Here is the ddl script for
creating the indexes</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">&nbsp; CREATE UNIQUE<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; INDEX&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.X1FTNRC2<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.FTNREC2_CATCTRL<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (CARRIER_CD&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,TARIFF_CD&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,FOOTNOTE_CD&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,CATEGORY_NO&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,SEQUENCE_NO&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,CREATE_TS&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
);</font></span></div>
  <div>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">&nbsp; CREATE UNIQUE<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; INDEX&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.X2FTNRC2<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.FTNREC2_CATCTRL<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (FTNREC2_SG&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
);</font></span></div>
  <div>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">&nbsp; CREATE <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; INDEX&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.X3FTNRC2<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
PARGRP.FTNREC2_CATCTRL<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (BATCH_CI&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,BATCH_NO&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
ASC<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
);</font></span></div>
  <div align="left" dir="ltr"><span class="558574612-16082005"></span>&nbsp;</div>
  <div align="left" dir="ltr"><span class="558574612-16082005"><font
 color="#0000ff" face="Arial" size="2">David</font></span></div>
  <br>
  <div class="OutlookMessageHeader" align="left" dir="ltr" lang="en-us">
  <hr tabindex="-1"><font face="Tahoma" size="2"><b>From:</b> Satheesh
Bandaram [<a class="moz-txt-link-freetext" href="mailto:satheesh@Sourcery.Org">mailto:satheesh@Sourcery.Org</a>]
<br>
  <b>Sent:</b> Friday, August 12, 2005 3:20 PM<br>
  <b>To:</b> Derby Discussion<br>
  <b>Subject:</b> Re: Error when running a delete all a 2nd time<br>
  </font><br>
  </div>
Hi Peart,<br>
  <br>
The error is really strange... I can't spot what could be causing the
problem here. Would it be possible for you to make a complete
reproduction?<br>
  <br>
Satheesh<br>
  <br>
Peart, David E. wrote:<br>
  <blockquote
 cite="mid8FA12926CCB8EC4CB47333C9B65F95D3015EDEE0@EMAIL.atpiad1.local"
 type="cite">
    <meta content="MSHTML 6.00.2900.2523" name="GENERATOR">
    <div><font face="Arial" size="2"><span class="201554417-10082005">I'm
getting the following internalError when I try and delete from a table
after I have populated it.&nbsp; Has anybody seen this error or know whats
causing it.&nbsp; It only happens with this table (find the ddl attached),
other tables are fine</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">I've
using this to do some TDD. </span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">a)
So I delete the contents of the table in a class setup</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">b)
load the data</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">c)
after all tests have run, delete the contents of the table</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005"></span></font>&nbsp;</div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">It's
during the 'c' step this occurs, and after I get this any attempt to
delete from the table produces this error.</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005"></span></font>&nbsp;</div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">Any
help would be appreciated as this is driving me crazy.</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005"></span></font>&nbsp;</div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">MessageID
= "XJ001.U"</span></font></div>
    <div><font face="Arial" size="2"><span class="201554417-10082005">SQLState
= "XJ001"</span></font></div>
    <div>&nbsp;</div>
    <div><font face="Arial" size="2">net.atpco.common.dataaccess.errors.DataAccessApplicationException:
unexpected error occurred in attempt to execute SQL: Java exception:
'No run method: java.lang.InternalError'.; <br>
Caused by --&gt; <br>
java.lang.InternalError: No run method<br>
&nbsp;at
org.apache.derby.impl.sql.execute.DeleteCascadeResultSet.open(DeleteCascadeResultSet.java)<br>
&nbsp;at
org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java)<br>
&nbsp;at
org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java)<br>
&nbsp;at
org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(EmbedPreparedStatement.java)<br>
&nbsp;at
org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeUpdate(EmbedPreparedStatement.java)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.MockJDBCDAO.createUpdateDelete(MockJDBCDAO.java:393)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.MockJDBCDAO.delete(MockJDBCDAO.java:442)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.FootNotesJDBCDAOFake.delete(FootNotesJDBCDAOFake.java:93)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.GenericFootNotesJDBCDAO.delete(GenericFootNotesJDBCDAO.java:208)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.GenericFootNotesDaSvc.delete(GenericFootNotesDaSvc.java:148)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.GenericFootNotesDaSvc.delete(GenericFootNotesDaSvc.java:152)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.FootNotesDaSvcTest.deleteSeedData(FootNotesDaSvcTest.java:207)<br>
&nbsp;at
net.atpco.rules.footnotes.server.dataaccess.FootNotesDaSvcTest$1.setUp(FootNotesDaSvcTest.java:41)<br>
&nbsp;at junit.extensions.TestSetup$1.protect(TestSetup.java:18)<br>
&nbsp;at junit.framework.TestResult.runProtected(TestResult.java:124)<br>
&nbsp;at junit.extensions.TestSetup.run(TestSetup.java:23)<br>
&nbsp;at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:329)<br>
&nbsp;at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:218)<br>
&nbsp;at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:151)<br>
&nbsp;at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:151)</font></div>
    <div>&nbsp;</div>
    <div>&nbsp;</div>
  </blockquote>
</blockquote>
</body>
</html>


Mime
View raw message