<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">A fast way to do what Steve is
suggesting for the ID numbers would be to do a search and replace
in OpenOffice Writer. Here's how:<br>
<br>
In the Find and Replace Window click on the "More Options" button
then select the "Regular Expressions" box.<br>
<br>
Now, because the existing numbers are single, double and triple
digits, we would need to do a find and replace for each set.<br>
<br>
Start with the set of the largest numbers - triple digits (ie,
122, 456, 786, etc)<br>
<br>
In the Find box, put this: id="[:digit:]{3}"<br>
In the Replace box, put this: id="1&<br>
Click on Replace All (for example: this will change id="122" to
id="1id="122", an intermediate step<br>
Now do a search and replace for 1id=" and replace with 1 (this
will change the example from id="1id="122" to id="1122", which is
what you want.<br>
<br>
You do it this way so that you are adding 1000 to all the numbers
instead of just appending "100" to the numbers, which would result
in "1002", "10044", "100122", which is not what you want. Also
we have to start with the largest so that we don't inadvertently
find the wrong numbers as we process the file. For instance, if
we changed "2" to "12", then when we search for 2 digit numbers
next we would find that and change it to "112", which is not what
you want.<br>
<br>
So the next search and replace would be for 2 digit numbers.<br>
Search for id="[:digit:]{2}" and Replace with id="1&<br>
Then search for 1id=" and Replace with 10 (notice this is
different than the first set of numbers, for which we replaced
with just 1)<br>
For example: this will change 44 to 1044<br>
<br>
The last search and replace would be for single digit numbers<br>
Search for id="[:digit:]{1}" and Replace with id="1&<br>
Then search for 1id=" and Replace with 100<br>
For example: this will change 2 to 1002<br>
<br>
Of course, if you're not sure that you don't have more than 1000
entries in your file, you can start by searching for 4 digit
numbers. If you do find 4 digit numbers then you'll want to
increase the numbers by 10000, not 1000 and take that into account
when changing the intermediate step for each set of digits.<br>
<br>
Bill<br>
<br>
<br>
On 7/6/2012 11:18 AM, Steve Slevinski wrote:<br>
</div>
<blockquote cite="mid:4FF70FF1.4080009@signpuddle.net" type="cite">
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
<br>
<div class="moz-cite-prefix">On 7/4/12 4:24 AM, MARIA GALEA wrote:<br>
</div>
<blockquote
cite="mid:534c215f09f2deff4c735a182eb3681c.squirrel@www.um.edu.mt"
type="cite">
<pre wrap="">Hi Steve and the List,
For Maltese Sign Language we have 3 Puddles that have been used - the
Literature, the Dictionary and the Private Puddle.
I would like to organize the entries so I would like to move things to and
from these different Puddles. Is there any way I can do this fast without
having to open each separate entry and copying it into another Puddle and
then deleting it..?
Thanks!
maria</pre>
</blockquote>
Hi Maria,<br>
<br>
The best option I can think of would be to download and edit the
XML files directly. If you downloaded each puddle's XML file, you
could use a text editor to quickly copy and paste entries between
the XML documents.<br>
<br>
The biggest problem would be that each entry in a puddle must have
a unique ID number. If you copied entries from one puddle to
another, you would have to make sure the IDs were unique. Looking
at 2 of the Malta puddles, it looks like all of the IDs are less
that 1,000. So to copy an entry from one puddle to the other, the
safest way would be to add 1,000 to the ID numbers.<br>
<br>
Here is an example:<br>
<entry id="2" cdt="1208941776" mdt="1208941776" usr="LSM"><br>
<term>M518x515S10e00482x485S17610502x499</term><br>
<term><![CDATA[GHOXRIN]]></term><br>
<term><![CDATA[TWENTY]]></term><br>
</entry><br>
<br>
If you wanted to copy this from one puddle to another, you would
cut it from one XML file and paste it into the other XML making
sure to change the <b>id="2"</b> to be <b>id="1002"</b>.<br>
<br>
It's not the most elegant solution, but it could work. If you
want to do this, I can work with you. We would lock the target
puddles so that they could not be edited. You would download and
update the XML files. Then I could import the new XML files and
overwrite the puddles.<br>
<br>
I can't think of an easier way to do this.<br>
<br>
Regards,<br>
-Steve<br>
</blockquote>
<br>
<br>
</body>
</html>