Altova XMLSpy 2025 Professional Edition

DB Import Based on XML Schema

Home Prev Top Next
icDBImportFromXMLSchema

The DB Import Based on XML Schema command creates an XML document which is valid according to a given XML Schema and contains data imported from a database. For this feature, the following databases are supported:

 

Microsoft Access 2000 and 2003

Microsoft SQL Server

Oracle

MySQL

Sybase

IBM DB2

 

The data to be imported is determined by the table that is selected in the database. With the required XML Schema (that on which you wish to base the import) as the active document in Schema View, connect to the database. Then select the table/s you wish to import, and click Import. The data is imported into an XML document, and the document has the structure of the XML Schema that was active when the data was imported.

 

In the example below, data from an MS Access database is imported with an XML Schema active in Schema View. These would be the steps to carry out for the import:

 

1.Open the schema file in Schema View (screenshot below).

imp-based-on

2.Select the menu command DB Import based on XML Schema. This opens the Connect to Data Source dialog.

3.Select the Microsoft Access (ADO) option and click Next.

4.Click Browse and select the database file. Then click Next.

5.In the DB Import Based on XML Schema dialog which pops up, go to the Tables tab, select one or more tables you wish to import (for example, Altova), then click Import. The table is imported into an XML document that is displayed in Grid View.

 

Datatype conversions

Information about the conversion of database datatypes to XML Schema datatypes is listed in the Appendices.

 

© 2018-2024 Altova GmbH