如何为此要求内部加入水晶报告 [英] How to inner join in crystal report for this requirement

查看:75
本文介绍了如何为此要求内部加入水晶报告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的应用程序中使用了水晶报告。两个表用于数据源。

表1和表2。在这个

Table1.Id = Table2.head



我使用这个字段加入两个表格。

一些情况Table1.Id = Table2.cato是相等的

现在我需要在Table2.cato的地方打印Table1.category



表1



Id名称分类

1 BAb SA12

2 Nag SA13

3 NAE SA14

4 HIP SA15

5 DRT SA16



表2

Head Cato

1 4

2 4



需要输出价格低于



HName Catogory

SA12 SA15

SA13 SA15



但我得到< br $>


HName Catogory

SA12 4

SA13 4





然后如何在4的位置显示SA15

可以使用公式字段可用于此或任何..

解决方案

在水晶报告中,必须有三张桌子

table1,table2,table3(ta ble1,别名为table3)



是的,您可以使用不同的别名多次添加单个表格。



链接table1.id到table2.head和table2.cato到table3.id

现在,将table1.category和table3.category放在水晶报告中



就是这样。它应该为你做的伎俩。 :thumbsup:

In my application used a crystal report. Two Table are used for datasource.
Table1 and Table2. In this
Table1.Id=Table2.head

I inner join two table using this fields.
some cases Table1.Id=Table2.cato is equal
Now I need to print Table1.category in the place of Table2.cato

Table1

Id Name Category
1 BAb SA12
2 Nag SA13
3 NAE SA14
4 HIP SA15
5 DRT SA16

Table2
Head Cato
1 4
2 4

OUTPUT REQUIRED Is below

HName Catogory
SA12 SA15
SA13 SA15

But I got

HName Catogory
SA12 4
SA13 4


Then how to display SA15 in the place of 4.
may Formula fields can use for this or any ..

解决方案

In crystal report, have to have three tables
table1, table2, table3(table1 with alias as table3)

yes, you can add single table multiple times with different aliases.

link table1.id to table2.head and table2.cato to table3.id
and now, place table1.category and table3.category in crystal report

That''s it. It should do the trick for you. :thumbsup:


这篇关于如何为此要求内部加入水晶报告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆