各位csdn的兄弟姐妹,可以帮我解决这个问题吗?我要求的fastreoprt如下:
报表标题: Report
分组头: a b
主项数据: c d
其中我的主项数据是根据分组头的条件得到的,比如:
分组头的数据是这样得到:
select a,b from table1;我的主项数据是这样得到:
select c,d from table2 where table2.c=table1.a也就是说必须先得到a,以此为条件得到c,这样应该怎么做啊?
报表标题: Report
分组头: a b
主项数据: c d
其中我的主项数据是根据分组头的条件得到的,比如:
分组头的数据是这样得到:
select a,b from table1;我的主项数据是这样得到:
select c,d from table2 where table2.c=table1.a也就是说必须先得到a,以此为条件得到c,这样应该怎么做啊?
select a.a, a.b, b.c, b.d from table1 a, table2 b where a.a=b.c order by a.a, a.b然后分组头用数据集中的a, b字段
主项数据用数据集中的c,d字段列
一定可以实现你要的功能!
---作为主项数据,请注意这里的条件a是从上一个select语句中得到的也就是说我要得到的数据是:
a b c
50 good bad
15 well 50
14 done 50