Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Import XML with multiple childs


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

Recommended Posts

  • 2 weeks later...
Posted (edited)

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
Posted

The way it looks there can be multiple Articles and multiple Packages - and each package can have multiple PackageLines. You need to specify what do you want to import into which table.

Posted

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

Posted

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

Posted

I suppose I can add the packages along with the article because it carries the same articlenumber or can I import the package using the article number?

And Thank you very much for all of this.

Posted

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.

Posted

thank you

Even though this is a physical file for import, how does HTTP request work? What url do you put in for the Import XML script step?

RB

This topic is 5375 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.