Check for any unusual characters in the data you are exporting.
For More Information see: SAXParseException on exporting XML with XSLT specified if the field contains an invalid character.
This is one of many acknowledged bugs that can be found in the Known Bug List thread here in the Report an Issue section of the forum.
It can also be downloaded as a database file from: https://www.dropbox.com/s/jt09b82i0xijbu3/FMP%20Bugs.zip
Here's a procedure that may work for you. Basically what I'm doing is creating character 0x14 that was in your error message. This way you can copy it and then paste it into the Find/Replace. This is different than the normal find mode you're used to. this is more like Find in Word or Excel.
- Create a new FM DB file and add a calc field with the following formula. Char ( 14 )
- Create 1 record in this DB
- Go to the field you created and select all. Note, you will not be able to see the character..
- Copy what you selected.
- Go to your database and find the records modified since the last successful export
- Go Edit > Find/Replace and paste the invisible character into the field "Find what:"
- Click "Find Next" This may take awhile if you have a lot of records. Basically this goes from record to record until it finds the pasted character.
- If this is successful delete the contents of the field it stops at and retype it manually. Don't copy and paste.
- Repeat 7 & 8 until no more instances of the character are found.
Thanks. I'll try those methods. It seems fairly straight forward.
Once you figure out which fields have the problem characters, you can set up an auto-enter calculation on that field to automatically remove them in the future. (Or use Replace Field contents to "clean up" batches of newly imported data...)
I wan't able to isolate the record or the filed with the faulty character using your steps Brian. I made a database and made the invisible character that you mentioned. It doesn't seem to even take up a space. I searched for it using find/replace in the most recent records and then I went through all of my records in a number of different tables.
So I tried to find if I could export by limiting the export to a small amount of records and then made larger and larger exports. I was able to isolate the faulty records down to a smaller and smaller range until I found the record with the 0x14. Then I was able to find the field with 0x14 through a similar process of elimination. What more would I be doing on a Saturday night?!
Any way I followed your advice and retyped the faulty information and it all exports quite nicely now. So thanks very much for your advice. It was bugging me (excuse the pun) all day.
I'm just wondering though if I want to prevent this in the future from happening and I want to follow Phil's advice in using an auto-enter calculation how can I do this if the character won't be found in the first place?
The Substitute function should work to eliminate specific unwanted characters. The Filter function, on the other hand can be used to keep all wanted characters without explicitly identifying all characters you want to exclude. That can be a better option, but does require setting up an extensive list of characters to keep in both upper and lower case.
Substitute ( self ; "a" ; "" ), would remove the lower case "a' from the field. and you can use the Char function in place of "a" if you know the character code.
Filter ( self ; "abcdefghijklmnopqrstuvwxyz" )
Would exclude all characters except the lower case letters "a" through "z".