Jump to content

Creating a XML file from table with multiple records


pioneerx01
Go to solution Solved by pioneerx01,

Recommended Posts

Yes, I am going to be one of those guys today. I have never done XML anything, besides past 2-3 hours or so, and I am getting frustrated. I have learned how to create simple XML files and save them. I am however having hard time figuring out how to create and XML file when trying to access an table from databse. I am looking to export from "registered_users" table all "registrations" and include "first_name", "last_name" and "age"

 

Sample:

 

<registered_users>

   <registration>

      <first_name>Bob</first_name>

      <last_name>Smith</last_name>

      <age>36</age>

   </registration>

   <registration>

      <first_name>Jack</first_name>

      <last_name>Miller</last_name>

      <age>45</age>

   </registration>

</registered_users>

 

It would be nice if the file would be saved as spearate "all_users.xml"

 

Any help would be appreciated

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.