关于mySql查询的有关问题 高分

WBOY
Release: 2016-06-13 10:01:26
Original
929 people have browsed it

求助关于mySql查询的问题 高分
一.数据表的结构:

1.主表invoice:

字段:InvoiceCode       InvoiceDate       PartnerCode       ProgramCode         ……

            IN2007031001       2007-03-04               ICBC                 AA                       ……

            IN2007031002       2007-03-05               ICBC                 BB                       ……

            IN2007031003       2007-03-10               ICBC                 AA                       ……

                    ……                     ……                     ……               ……                     ……

2.从表一invoicelist:

字段:InvoiceCode       ……     ItemBundleCode       QtyTxn       Price       Amount  

            IN2007031001     ……       IB2007020111           10             25.00       250.00

            IN2007031001     ……       IB2007020112           10             15.00       150.00

            IN2007031001     ……       IB2007020113           5               20.00       100.00

……                 ……             ……       ……             ……         ……

            IN2007031002     ……       IB2007020111           8                 5.00       40.00

            IN2007031002     ……       IB2007020112           7                 6.00       42.00

            IN2007031002     ……       IB2007020113           14               10.00     140.00

……                 ……             ……       ……             ……         ……

3.从表二invoiceuser:

字段:InvoiceCode       ……     Descrption               QTY           UnitPrice   Amount  

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!