Jump to content
Server Maintenance This Week. ×

Import XML with multiple childs


WingMaker

This topic is 5168 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • 2 weeks later...

Attached is an example of the xml file that I am using. I need to create a stylesheet to import into filemaker. Some of the elements in the xml file do not read for filemaker.

And sometimes there could be more than one article.

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

Cengage

EPAC-123456789

Cengage

Jimmy Page

145 Dart Ave

Akron

44301

OH

USA

false

2

1432

2

9781234567890

Three Cups Of Tea

Jeff Beck

Cengage

0.466

7.95

25

12345

11.925

1432

2

25

Edited by Guest
Link to comment
Share on other sites

Essentially there would be three tables...

One for the ShippingAddress or what should be the top level table. The xml should import once into this table.

A table for the articles with the FK of the ShippingAddress table. The xml should import the articles into this table.

Then import the packages into a table. With FK of the articles.

Could I do all this in one import with one stylesheet or do I need to do multiple things?

thanks

Link to comment
Share on other sites

Filemaker cannot import into more than one table at a time. You need a specific stylesheet for each table.

Attached are two sample stylesheets, one for importing the order and one for the articles.

Then import the packages into a table. With FK of the articles.

I don't see that Packages have a FK to Articles - only PackageLines do. Anyway, I believe this should be enough to get you started.

Archive.zip

Link to comment
Share on other sites

From what I see in the sample, an Article could be split into several PackageLines - and these lines could be in the same Package and/or in different Packages.

I am not sure what you intend to do with the imported data. If you want to preserve the original structure, then you need 4 tables and 4 imports.

Link to comment
Share on other sites

This topic is 5168 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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