[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details

sql to XML with specific schema

Asked by k1ng87 in Extensible Markup Language (XML), Microsoft Access Database

any one know how I can export a sql query to this type of an XML format? This is a EDI project from one of our customers and they are asking that all invoices be sent of EDI. We can do it in either XML, CSV, or X12. I figured that XML would be easier as I can query all the data required from 4 different tables.
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
<HDS_INVOICE>
    <IVH>
	<sender_id>3333</sender_id>
	<receiver_id>3400</receiver_id> 
	<batch_invoice_file_id>987654321</batch_invoice_file_id>  
	<invoice_sequence_id>12345678</invoice_sequence_id>
	<supplier_vendor_no>1234</supplier_vendor_no>
	<invoice_number>12345678</invoice_number> 
	<invoice_date>20080303</invoice_date>
	<po_number>23456</po_number>
	<po_date>20080225</po_date>  
	<transaction_type>DI</transaction_type>  
	<currency_code>CAD</currency_code>  
	<bill_to_code>1234</bill_to_code>
	<bill_to_name>Test Vendor</bill_to_name>
	<bill_to_address>155 Rexdale Blvd.</bill_to_address>
	<bill_to_city_name>Toronto</bill_to_city_name> 
	<bill_to_state_code>ON</bill_to_state_code>
	<bill_to_postal_code>M9W5Z8</bill_to_postal_code>  
	<bill_to_country_code>CA</bill_to_country_code> 
	<ship_to_code>1234</ship_to_code>
	<ship_to_name>Test Vendor</ship_to_name>
	<ship_to_address>155 Rexdale Blvd.</ship_to_address>
	<ship_to_city_name>Toronto</ship_to_city_name> 
	<ship_to_state_code>ON</ship_to_state_code>
	<ship_to_postal_code>M9W5Z8</ship_to_postal_code>  
	<ship_to_country_code>CA</ship_to_country_code> 
	<shipped_date>20080305</shipped_date>
	<delivered_date>20080305</delivered_date> 
	<invoice_amount_after_tax>202.26</invoice_amount_after_tax>
	<invoice_amount_less_tax_sac>200.00</invoice_amount_less_tax_sac>
	<GST_amount>10.00</GST_amount>  
	<PST_amount>16.00</PST_amount>  
	<GST_number>12345678RT001</GST_number>  
	<PST_number>3456789</PST_number>  
	<no_of_line_item>2</no_of_line_item>
    </IVH>
<SACLoop>
          <SAC>
	<ac_ind>C</ac_ind>
	<ac_code>D240</ac_code>
	<amount>2.50</amount>
	<description>Freight Amount</description>
          </SAC>
          <SAC>
	<ac_ind>A</ac_ind>
	<ac_code>D500</ac_code>
	<amount>0.50</amount>
	</ac_handling_code>
	<description>Defect Allowance for item</description>
          </SAC>
</SACLoop>
<IVDLoop>
 <IVD>
	<line_number>1</line_number>
	<quantity_invoiced>10</quantity_invoiced>
	<uom>EA</uom>
	<unit_price>10.0000</unit_price>
	<resale_price></resale_price>
	<upc_ean_ind>UP</upc_ean_ind>
	<upc_ean_code>881038001821</upc_ean_code>
	<sku_code>Buyer Style 1</sku_code>
	<supplier_product_code>Item Catalogue 1</supplier_product_code>
	<item_description>Item Description</item_description>
	<buying_pack_quantity>1</buying_pack_quantity>
	<Inner_pack_size>1</Inner_pack_size>
	<sln_uom>EA</sln_uom>
          </IVD>
          <IVD>
	<line_number>2</line_number>
	<quantity_invoiced>4</quantity_invoiced>
	<uom>EA</uom>
	<unit_price>25.0000</unit_price>
	<resale_price>25.0500</resale_price>
	<upc_ean_ind>UP</upc_ean_ind>
	<upc_ean_code>9781578702152</upc_ean_code>
	<sku_code>Buyer Style 2</sku_code>
	<supplier_product_code>Item Catalogue 2</supplier_product_code>
	<ISBN>0672325667</ISBN>
	<item_description>Item Description - Book</item_description>
	<buying_pack_quantity>1</buying_pack_quantity>
	<Inner_pack_size>1</Inner_pack_size>
	<sln_uom>EA</sln_uom>
          </IVD>
</IVDLoop>
<HDS_INVOICE>
[+][-]11/08/09 02:25 PM, ID: 25772260Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/08/09 03:42 PM, ID: 25772589Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/08/09 03:46 PM, ID: 25772603Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/09/09 10:17 AM, ID: 25778490Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/09/09 10:26 AM, ID: 25778549Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/09/09 10:28 AM, ID: 25778565Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/09/09 10:28 AM, ID: 25778568Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/09/09 10:37 AM, ID: 25778631Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/09/09 11:08 AM, ID: 25778930Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/09/09 11:15 AM, ID: 25778994Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/10/09 09:15 AM, ID: 25787481Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-92 - Hierarchy / EE_QW_3_20080625