Hi Josema,

I asked this some days ago too, but there was no real solution besides
hacking code of Xindice.

The <EquipmentTypes /> Tag, u have to set by yourself, cause u are  getting
a resultset.

the declaration can be killed by
----------------------------------------------
data= data+xml.substring(xml.indexOf("?>")+2);
-----------------------------------------------
for the

"xmlns:src="http://xml.apache.org/xindice/Query";
src:col="/db/xmtrader/Recording/Equipment/EquipmentType" src:key="mic"

stuff i found a really bad solution, it "overreads" just that stuff and
gives the string back to u without it.

   public String clearXpath(String tmp) throws Exception{
        String ausgabe = "";
        int pos = tmp.indexOf("xmlns:src=");

        while(pos != -1)
        {
            //bis pos ausgeben
            ausgabe= ausgabe + tmp.substring(0,pos);
            //System.out.println(ausgabe+":"+pos);

            tmp=tmp.substring(pos);
            //ende des schruts finden
            int nameendpos  =   tmp.indexOf(">");
            //System.out.println(">"+nameendpos);
            //set newtmp-text
            tmp=tmp.substring(nameendpos);
            pos = tmp.indexOf("xmlns:src=");
        }
        ausgabe = ausgabe + tmp;
        return(ausgabe);
    }


hope that helps


Reply via email to