来自MySql和C#的水晶报告中的两个不同的组树结构

时间:2014-04-03 03:20:40

标签: mysql crystal-reports c#-2.0

以下在所有表中都有唯一字段的数据库是ACCYEAR,BILLNO,BILLDATE。 如何获得两种不同的树结构,如下所示。

database name 'billing'
table name: BillDetails

|**********************
|----------> fields (BILLNO: 1, AccYear: 13-14,  BillDate : 03/04/2013, CUSTNAME_AND_ADDRESS: LEO,ZEON NAGARY)
|       |*********************************************************************************************************
|       |
|       |-------->table name: TransportDetails (record 1)
|       |   |     fields(Bill #     : 1
|       |       |       Acc_Year:    13-14 
|       |       |           Bill Date : 03/04/2013
|       |       |           Transport Sl# : 1
|       |       |           Trailer #     : TXT 4568
|       |       |           Driver #      : DRIVER1)
|   |   |
|       |   |       |---------->table name: Cargo Details: (record 1)
|       |   |       |                      fields(Bill #     : 1
|       |       |       |                      Acc_Year:    13-14
|       |       |       |                      Bill Date : 03/04/2013
|       |   |-------------->|                      Transport Sl# : 1
|       |               |                      CargoSlNo:1
|       |               |                      CargoPkgs: 45 WoodenCrates)
|       |           |
|       |           |---------->table name: Cargo Details: (record 2)
|       |                                   fields(Bill #     : 1
|       |                                       Acc_Year:    13-14
|       |                                       Bill Date : 03/04/2013
|       |                                       Transport Sl# : 1
|       |                                       CargoSlNo:2
|       |                                       CargoPkgs: 20 PLTS)
|   |
|       |-------->table name: TransportDetails (record 2)
|           |     fields(Bill #     : 1
|               |       Acc_Year:    13-14 
|               |           Bill Date : 03/04/2013
|               |           Transport Sl# : 2
|               |           Trailer #     : TXZ 0541
|               |           Driver #      : DRIVER2)
|       |
|           |       |---------->table name: Cargo Details: (record 1)
|           |       |                      fields(Bill #     : 1
|               |       |                      Acc_Year:    13-14
|               |       |                     Bill Date : 03/04/2013
|           |-------------->|                     Transport Sl# : 1
|                       |                     CargoSlNo:1
|                       |                     CargoPkgs: 52 CTNS)
|                   |
|                   |---------->table name: Cargo Details: (record 2)
|                                           fields(Bill #     : 1
|                                               Acc_Year:    13-14
|                                               Bill Date : 03/04/2013
|                                               Transport Sl# : 1
|                                               CargoSlNo:2
|                                               CargoPkgs: 10 BALES)
|
|--------------> table name: DocumentDetails (record 1) :
|       |        Document-details-1:
|       |     
|   |
|   |
|       |---table name: ProductDetails:(record 1)------>| table name: ProductDetails:(record 1)
|       |                   |       |   Name : ccc
|       |                   |       |   Manufacturer: pppp
|       |                   |       |   Price : 45000
|   |                   |   |
|       |                   |   |---->|---TABLENAME:PODETAILS(RECORD 1)
|       |                   |         |---TABLENAME:PODETAILS(RECORD 2)
|       |                   |
|       |                   |
|       |                   |------>| table name: ProductDetails:(record 2)
|       |                           |   Name : GFFGH
|       |                           |   Manufacturer: NUGK
|       |                           |   Price : 1285000
|   |                       |
|       |                       |---->|---TABLENAME:PODETAILS(RECORD 1)
|       |                                     |---TABLENAME:PODETAILS(RECORD 2)
|       |        
|       |   
|       |   
|       |---table name: ProductDetails:(record 2)-------|-------->| table name: ProductDetails:(record 2)
|                                   |         |     Name : ccc
|                               |         |     Manufacturer: pppp
|                               |         |     Price : 840000
|                           |     |
|                               |     |---->|---TABLENAME:PODETAILS(RECORD 1)
|                               |           |---TABLENAME:PODETAILS(RECORD 2)
|                               |
|                               |
|                               |-------->| table name: ProductDetails:(record 2)
|                                         | Name : GFFGH
|                                         | Manufacturer: NUGK
|                                         | Price : 950000
|                                 |
|                                     |---->|---TABLENAME:PODETAILS(RECORD 1)
|                                               |---TABLENAME:PODETAILS(RECORD 2)
|
|
|
|-----------------> PAYMTDETAILS(multi records)

0 个答案:

没有答案