on 01-26-2017 7:56 AM
Dear Gurus,
I am now working to design sales invoice, delivery note, return those related document in crystal report.
As I found that most of them are similar, and would like to find out can I use 1 crystal to fulfill all the documents.
Based on my understanding, print a form would only pass out a single parameter DocKey from SAP b1.
Can I add one more parameter that indicate the form is printed from sales order e.g. SO to the crystal report? As I would like to like where is the printing action comes from.
Or can I add a default parameter that will automatic pass to crystal report to perform the same behavior?
P.S. may not consider any add-on module to handle the problem but would like to have the idea
Many thanks.
Best Regards
Daniel
Hi Daniel,
Have you ever tried creating 1 crystal report, Add a table let's say OINV, show the DocNum and CardCode.
Import it into Invoice Layout. run the report, as expected, you will get the OINV DocNum and CardCode on the report.
Next, the same crystal report, Load it into Sales Order Layout, or even, Purchase Invoice layout.
Now run the report. You will notice that SAP will handle it for you. The report will give you the Data from ORDR or OPCH.
Regards
Edy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
SAP knows which standard table belongs to Documents, in runtime, ALL DOCUMENTS table will be replaced by the scope of the printing, ie when printing invoices, ALL DOCUMENT tables will be replaced by the 'INV' tables.
However, there are 2 catch here :
Lastly, there are other parameters passed into the CR during runtime.ie.
There might be other parameters not included here.
Regards
Edy
I think Crystal report itself can't give you the ability to switch tables during the runtime, but we can use store procedure to achieve it. Basically the SP will act as a Data Access Layer between DB and Crystal Report layout.
Lan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
If you use one of the SAP sample reports as your base, the SAP stored procedure will already be in there and will fulfill these requirements. The SAP sample reports can be downloaded from the documentation area if you do not already have them in your database
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here object type details and used it as parameter,
DECLARE @sTableID NVARCHAR(4)
IF @ObjectId@ = '23' SELECT @sTableID = 'QUT'
IF @ObjectId@ = '17' SELECT @sTableID = 'RDR'
IF @ObjectId@ = '22' SELECT @sTableID = 'POR'
IF @ObjectId@ = '13' SELECT @sTableID = 'INV'
IF @ObjectId@ = '14' SELECT @sTableID = 'RIN'
IF @ObjectId@ = '15' SELECT @sTableID = 'DLN'
IF @ObjectId@ = '203' SELECT @sTableID = 'DPI'
IF @ObjectId@ = '18' SELECT @sTableID = 'PCH'
IF @ObjectId@ = '19' SELECT @sTableID = 'RPC'
IF @ObjectId@ = '112'SELECT @sTableID = 'DRF'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Find below answers to your question:-
can I use 1 crystal to fulfill all the documents?
Yes, you can use one crystal layout for all sales documents by creating single stored procedure. In this stored procedure, you have to add object type each document. Dockey should be docentry of the document.
Regards,
Nagarajan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
103 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.