Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Transforming from XML to Filemaker

Featured Replies

I am not so good in making XSLT files, maybe someone can help me to translate the file below to filemaker 9 or know where i can find information how to do this file.

<?xml version="1.0" encoding="utf-8"?>

Edinburgh University Press

y.y

x.x

20090618

eng

T40

02

02

0748621237

03

9780748621231

15

9780748621231

BB

Traditions in World Cinema

01

African Filmmaking

North and South of the Sahara

1

A01

Armes, Roy

Prof.

Roy

Armes

Emeritus Professor of Film

Middlesex University

You need to tell us which data you want to import, into which fields.

BTW, your example is NOT a valid XML document: the "contributor" element is missing a closing tag.

  • Author

Hello,

The file below should now be complete.

9780748621231 to field isbn13 in out filemaker program

Traditions in World Cinema to field title

Armes to field author

The file containing more tags i origional but hopefuly i can do this by my own if You help me how to start the one´s above.

Thank You for taking Your time! / marie

<?xml version="1.0" encoding="utf-8"?>

Edinburgh University Press

Catriona Murray

[email protected]

20090618

eng

T40

02

02

0748621237

03

9780748621231

15

9780748621231

BB

Traditions in World Cinema

01

African Filmmaking

North and South of the Sahara

1

A01

Armes, Roy

Prof.

Roy

Armes

Emeritus Professor of Film

Middlesex University

Roy Armes is Emeritus Professor of Film at Middlesex University and author of numerous books on cinema including Arab and African Film Making (with Lizbeth Malkmus), Dictionary of North African Film Makers, and Postcolonial Images: Studies in North African Film. His work has been translated into 13 languages, including Japanese, Chinese and Arabic.

It would be better if you zipped and attached the entire document. Filemaker will not import your shortened version because it doesn't pass validation against the DTD specified in the DOCTYPE declaration.

Another issue is the ISBN13. There are 3 'productidentifier' elements, and each has its own 'b244' tag. They are distinguished by the 'b221' tag, which I presume to be a type ID. AFAICT, both type "03" and "15" contain the ISBN13 code - so you'll need to specify which one to pick (in the attached stylesheet, I have picked type "15").

Hopefully the attached will work for you once you run it against the full XML source. Otherwise you'll have to remove the DOCTYPE declaration from the source.

Import.xsl.zip

  • Author

Hello again.

I have now added a zipfile with the whole original file. It´s ok to use 15 for isbn13.

Thank´s again / marie

edin180609.xml.zip

I am afraid that too doesn't pass validation against the DTD. I am not sure if the blame lies with the document or with the DTD - I rather suspect both. You should contact the source of the data and advise them of the problem.

Meanwhile you can work around the issue by removing the DOCTYPE declaration from the source document, or by processing it with some external XSLT processor (you'd have to perform tests to find one that doesn't validate), then importing the result directly into Filemaker.

---

P.S. Not that it matters much in the circumstances, but the source filename must have .xml extension!

Edited by Guest

  • Author

Hello again,

I don´t know what you mean with DOCTYPE. How do I remove the DOCTYPE declaration from the source document?

/Marie

By deleting the second line, that reads:

  • Author

Hello again,

I have tried all the things you have suggested without success.

What do you think about converting the XML-files to CSV-file and import this fiel into Filemaker?

I have tried different transformer from XML to CSV but they split the information into different categories. I want all the information on one row.

I hope you have time to help me.

/Marie

I am not sure what you did. If I remove the DOCTYPE declaration from your previously posted source file, Filemaker imports it without a hitch using the stylesheet I have posted earlier (I am attaching both these files, so you can try it yourself).

Simlarly, if I process your original source file using my stylesheet in an external XSLT processor, I can then import the result directly into Filemaker (since it is already transformed into Filemaker's FMPXMLRESULT grammar, no stylesheet is required for the import).

Archive.zip

  • Author

Hello Again,

Thank You for Your help, the file works fine now but may I have You help again ??? We need to extract row j151 and the only unique row i have is row j152 wich always have value GBP in the file´s we will import.

Can You Please help me?

PROF

02

PROF

38.95

USD

US

20090621

02

PROF

02

PROF

21.00

GBP

GB

Z

0

21.00

0

20090621

02

PROF

02

PROF

31.00

EUR

GB

20090621

02

PROF

02

PROF

31.00

EUR

GB

20090621

I am not sure what j152 has to do with this. Why can't you simply import j151?

NOTE:

Please do not post partial code. There's no way I could have seen from that snippet that the element is a child of , and that is a child of . These details are crucial, as you can see in the modified stylesheet.

Stylesheet.xsl.zip

  • Author

Hello,

Thank You for Your help again.

The file works fine now.

Do You have time to help me with another thing.

I need to import

1

Gandhi, Monica

and

3

Caughey, Aaron B

to the same tag with ";"separation

(Gandhi, Monica;Caughey, Aaron ??? . The name of the tag will be "totauthor"

01

blueprints Clinical Cases in Medicine

1

A01

Gandhi, Monica

Monica

Gandhi

2

A01

Gandhi, Monica

Oliver

bacon

3

A01

Caughey, Aaron B

Aaron B

Caughey

01

eng

I have done this using the same "ModifiedSource.xml" document as the source. I don't know how well this will work with the document you're quoting, which is completely different. Did you miss this part in my previous message?

Please do not post partial code.

Stylesheet.xsl.zip

  • Author

Hello again,

Tank You for Yor last file it works well. We import the value from b037 to author.

I have enclosed a xsl file and also a xml file.

Sometimes we miss a value in tag . Is it possible to import from tag to author when we do so?

/Marie

Stylesheet0702.zip

xx.zip

  • Author

Hello again,

Thank You for Your last file it works well as usual.

I will import different files to my database and sometimes containing tag

a "." . I will use this value

in a calculation so I need to change to a "," . Some of the files have a "," in origional so I do not need to change the value.

Do You have time to help me?

/ Marie

I am afraid I don't understand your question. Do you mean changing the decimal point to a comma?

  • Author

Yes,

/Marie

Try:


...



...

  • Author

Hello again.....

I need Your help again.

Is it possible for the system to write

"Definitivt slut" if = OI and "Tillgänglig" if = IP and "Slut" if = OP

/Marie

  • Author

Hello again.....

I need Your help again.

Is it possible for the system to write

"Definitivt slut" if = OI and "Tillgänglig" if = IP and "Slut" if = OP

/Marie

Stylesheet0702.zip

It's possible, and I think by now you should be able to do this yourself by using the element:

http://www.w3schools.com/xsl/xsl_choose.asp

  • Author

Ok!

Thank You for all help.

I hope i can comeback if i do not solve it :

Marie

I hope you will come back and report mission accomplished. :

  • Author

I am sorry but i have to report mission failed.

I have tried with the following without success.

Can You Please assist me? :

/ Marie

I see two problems here:

1. in the test, the text constant "eng" must be quoted;

2. The result needs to be the contents of the DATA element - not a new LanguageCode element:








Engelska



...











Or:















...





  • Author

Hello again,

I have tried to make a new xslt file but the file do not work. Filemaker show´s that nothing is avaliable to import.

Can You Please help me?

test0708.zip

stylesheet0708.xsl.zip

  • Author

Sorry,

Find the right xml enclosed

Marie

test0708.zip

XML is case-sensitive: "ONIXmessage" is not the same as "ONIXMessage", and "product" is not the same as "Product".

  • Author

Hello again,

I have tried with below but it still not working,

Have You Please an idea?

/ Marie

<?xml version="1.0" encoding="UTF-8"?>

0

I don't see closing tags for template and stylesheet.

  • Author

Hello again!

Now the file works fine :D

Thank´s

Marie

  • 8 months later...
  • Author

Will there be any way to exclude ""

from the xml file. Now i have to load the xml file into a wordprogram and delete the row

and after that import the file to filemaker

<?xml version="1.0" encoding="utf-8"?>

Edinburgh University Press

y.y

x.x

20090618

eng

T40

02

02

0748621237

03

9780748621231

15

9780748621231

BB

Traditions in World Cinema

01

African Filmmaking

North and South of the Sahara

1

A01

Armes, Roy

Prof.

Roy

Armes

Emeritus Professor of Film

Middlesex University

I believe this was discussed at the beginning of this thread, 9 months ago.

  • Author

Hello,

Before I only imported one file each week, now do I need to import the file every day.

Do You have a chance to update me? I have realy tried to find an own solution.

//Marie

  • Author

Please can anyone help me !

  • 5 years later...
  • Newbies

Sorry for bringing up an old thread, but I used the solution in this thread to extract data from an onix xml file. I get stuck when trying to import from a repeating field in the xml file, in particular, the author field has multiple repeating entries if there is more than one author. At the moment I can only pick up the first author. Can anyone give me any advice on how to modify the xsl file so that I can extract the other authors?

Please start a new thread and post your stylesheet as well as an example of your input. And make sure we understand how the input is supposed to map to your target table.

  • 1 year later...

The way to do such translations is

  1. To make export of 1 record pr table that you would like to import to with as low amount of fields as possible, yet as many as needed.
  2. Make one XSLT pr table you would like to translate your XML to; UBL as an example, using the exports from pt 1 as template
  3. Import once pr XSLT and you will have populated that field you exported in pt 1

Edited by ggt667

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.