Dim sql As String = "Select 产品名称,数量,日期 FROM {订单} INNER JOIN {产品} ON {订单}.产品ID = {产品}.产品ID"
Dim b As New CrossTableBuilder("统计表1",sql, "Sale")
b.HGroups.AddDef("产品名称")
b.VGroups.AddDef("日期","{0}月")
b.Totals.AddDef("数量")
b.HorizontalTotal = True
b.VerticalTotal = True
b.Build()
MainTable = Tables("统计表1")
从示例延伸,分组统计和汇总模式不可以吗?
dim b as new grouptableduilder ("统计表1",sql, "Sale")
....
dim b as new stutotalgroup ("统计表1",sql, "Sale")
....