Bookmark Topic Watch Topic
  • New Topic

how to do record based index?

 
Ishrayansh Nath
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Report post to moderator
This is sample.xml file

<Filter>
<Finfo>
<rec>1</rec>
<filterId>01</filterId>
<msgid>ADMCERR001</msgid>
<startTime>00</startTime>
<endTime>2359</endTime>
<filtDays>All</filtDays>
<notFiltCnt>10</notFiltCnt>
<filtCnt>30</filtCnt>
<custMesg>ADMCERR is not Filtered</custMesg>
<status>3</status>
</Finfo>
<Finfo>
<rec>2</rec>
<filterId>02</filterId>
<msgid>ADMCMSG001</msgid>
<startTime>0000</startTime>
<endTime>2359</endTime>
<filtDays>All</filtDays>
<notFiltCnt>10</notFiltCnt>
<filtCnt>30</filtCnt>
<custMesg>ADMCMSG is Filtered</custMesg>
<status>3</status>
</Finfo>
<!-- ***************************** -->
<!-- OS Module : File System Messages -->
<!-- ***************************** -->
<Finfo>
<rec>3</rec>
<filterId>03</filterId>
<msgid>ADMCFS001</msgid>
<startTime>0000</startTime>
<endTime>2359</endTime>
<filtDays>All</filtDays>
<notFiltCnt>10</notFiltCnt>
<filtCnt>30</filtCnt>
<custMesg>ADMCAVAYA is Filtered</custMesg>
<status>1</status>
</Finfo>
</Filter>


I have Dom parser it is giving the following o/p
1
01
ADMCERR001

I open & read this file manually and update this file.

suppose I delete the 2nd record of the file.

3 rd record should be taken as 2 nd record.

(actual Record should be n no of records)
how to do write java program?

pls Give the idea.
 
Madhav Lakkapragada
Ranch Hand
Posts: 5040
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please do not post duplicates. Continue the discussion in the XML forum.
Thanks.

- m
 
    Bookmark Topic Watch Topic
  • New Topic