如何使用三个sql表创建水晶报表 [英] How to create a crystal report using three sql tables

查看:72
本文介绍了如何使用三个sql表创建水晶报表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个包含三个表的数据库。

表名:

存款:dpid,date,custname,description, chqno,duedate,accname,金额

银行手续费:bankid,date,accountname,description,金额

期初余额:opbid,date,accountname,amount

我需要使用以上三个表创建一个水晶报表。如果我选​​择这三个表,它会显示所有数据正确如下,



date,custname,chqno,duedate,amount,bankid,date,金额,opbid,accountname,amoun



i需要列中的期初余额金额以及日期顺序中列中的其他两个金额。并且需要从期初余额中减去deopsit金额和银行cahrges金额。任何人都可以帮我找到一个好的答案

I have created a database contains three tables.
Table Names :
deposits : "dpid","date","custname","description","chqno","duedate","accname","amount"
bank charges : "bankid","date","accountname","description","amount"
Opening Balance : "opbid","date","accountname","amount"
I need to create a crystal report using above three tables.If i selected these three table it shows all the datas correctly like below,

"date","custname","chqno","duedate","amount","bankid","date","amount","opbid","accountname","amoun"

i need opening balance amount in a column and the other two amounts in a column in a date order. And need to substract deopsit amount and bank cahrges amount from opening balance amount. Can anyone help me to find a good answer for this

推荐答案

在水晶报表中,添加这三个表并按帐户名加入,之后你需要拖动删除要在报告中显示的字段。



对您有用,请告诉我。



谢谢。
In crystal report , add these three table and join them by account name , after that you need to drag and drop your fields which you want to show in report.

Is it useful for you , let me know.

Thank you.


在Visual Studio 2010中使用Crystal Reports生成报告 [ ^ ]



此链接有简单示例如何使用VS进行Crystal报表和SQL,同样你可以理解他在做什么,你可以为下两个表思考。
Generate a Report using Crystal Reports in Visual Studio 2010[^]

This link is having simple sample how to do Crystal report with VS and SQL, Likewise you can understand what he is doing and you can think bit for next two tables.


这篇关于如何使用三个sql表创建水晶报表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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