This discussion is archived
0 Replies Latest reply: May 10, 2011 4:16 PM by 727787 RSS

removeDocument command doesn't work

727787 Newbie
Currently Being Moderated
I'm using Oracle: Berkeley DB XML 2.4.16: (October 21, 2008) Berkeley DB 4.6.21: (September 27, 2007) Joined existing environment

I have a container in which a document can not be found with the removeDocument command, but it's found with other commands
e.g. 1 if I use getDocument and then printname, it is shown.
e.g. 2 if I use putDocument, an error message is claiming that the document is already exist

The removeDocument will work if I delete and then add the default index twice. Wonder if anyone know about this problem?

The following is the commands that I put into the shell, in case my description above doesn't make sense to you.

---------------------------------------------------------------------
dbxml> open database.dbxml

dbxml> getDoc
2 documents found

dbxml> printname
first.xml
second.xml

dbxml> removeDoc second.xml
stdin:4: removeDocument failed, Error: Document not found: second.xml

dbxml> putDoc second.xml
stdin:5: putDocument failed, Wrong number of arguments

dbxml> putDoc second.xml second.xml
stdin:6: putDocument failed, Error: Document exists: second.xml

dbxml> putDoc second.xml second.xml f
stdin:7: putDocument failed, Error: Document exists: second.xml

dbxml> delindex node-element-equality-string
Deleting default index type: node-element-equality-string

dbxml> addindex node-element-equality-string
Adding default index type: node-element-equality-string

dbxml> removeDoc second.xml
stdin:10: removeDocument failed, Error: Document not found: second.xml

dbxml> delindex node-element-equality-string
Deleting default index type: node-element-equality-string

dbxml> addindex node-element-equality-string
Adding default index type: node-element-equality-string

dbxml> removeDoc second.xml
Document deleted, name = second.xml

dbxml>

Edited by: user12056281 on May 10, 2011 4:15 PM

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points