shambhavi
7th September 2018, 14:27
I have witten the below code to print delivery scheme of sales contract, when i compile the same am not getting any error but am not able to get data which i wanted to print, i tried to debug the report their i got to know that it is not selecting record from table.
Please suggest anyone.
|******************************************************************************
|* tdsls3404m000 VRC B61O 10 dttt
|* Annexure for Delivery Scheme
|* bsp
|* 05-09-18 [13:39]
|******************************************************************************
|* Rev.No. 2 tdB61O10test 05 Sep 18 bsp
|* report created
|* Rev.No. 3 tdB61O10test 07 Sep 18 bsp
|* 12
|******************************************************************************
|****************************** declaration section ***************************
declaration:
table ttccom000
table ttdsls300
table ttdsls301
table ttdsls304
extern domain tcncmp r.comp
extern domain tccono r.cono
extern domain tcpono r.pono, r.sqnb
extern domain tcqrd3 r.quan
long year, mn, dy, hh, mm, ss
string year1(4)
string mn1(2)
string dy1(2)
string date1(10)
|*********************************************************************************
before.program:
r.comp=get.compnr()
detail.1:
before.layout:
get.cont.details()
functions:
function get.cont.details()
{
select tdsls301.*
from tdsls301
where tdsls301._index1 = {:tdsls301.cono, :tdsls301.pono, :tdsls301.cofc}
as set with 1 rows
selectdo
select tdsls304.*
from tdsls304
where tdsls304._index1 = {:tdsls304.cono, :tdsls304.pono, :tdsls304.cofc, :tdsls304.ddta}
and tdsls304.cono={:tdsls301.cono}
as set with 1 rows
selectdo
r.cono=tdsls304.cono
r.pono=tdsls304.pono
r.sqnb=tdsls304.sqnb
r.quan=tdsls304.qoor
utc.to.date(tdsls304.ddta, year, mn, dy, hh, mm, ss)
year1=str$(year)
mn1=str$(mn)
dy1=str$(dy)
date1=dy1&"/"&strip$(mn1)&"/"&year1
endselect
endselect
}
output of the code attached.
Please suggest anyone.
|******************************************************************************
|* tdsls3404m000 VRC B61O 10 dttt
|* Annexure for Delivery Scheme
|* bsp
|* 05-09-18 [13:39]
|******************************************************************************
|* Rev.No. 2 tdB61O10test 05 Sep 18 bsp
|* report created
|* Rev.No. 3 tdB61O10test 07 Sep 18 bsp
|* 12
|******************************************************************************
|****************************** declaration section ***************************
declaration:
table ttccom000
table ttdsls300
table ttdsls301
table ttdsls304
extern domain tcncmp r.comp
extern domain tccono r.cono
extern domain tcpono r.pono, r.sqnb
extern domain tcqrd3 r.quan
long year, mn, dy, hh, mm, ss
string year1(4)
string mn1(2)
string dy1(2)
string date1(10)
|*********************************************************************************
before.program:
r.comp=get.compnr()
detail.1:
before.layout:
get.cont.details()
functions:
function get.cont.details()
{
select tdsls301.*
from tdsls301
where tdsls301._index1 = {:tdsls301.cono, :tdsls301.pono, :tdsls301.cofc}
as set with 1 rows
selectdo
select tdsls304.*
from tdsls304
where tdsls304._index1 = {:tdsls304.cono, :tdsls304.pono, :tdsls304.cofc, :tdsls304.ddta}
and tdsls304.cono={:tdsls301.cono}
as set with 1 rows
selectdo
r.cono=tdsls304.cono
r.pono=tdsls304.pono
r.sqnb=tdsls304.sqnb
r.quan=tdsls304.qoor
utc.to.date(tdsls304.ddta, year, mn, dy, hh, mm, ss)
year1=str$(year)
mn1=str$(mn)
dy1=str$(dy)
date1=dy1&"/"&strip$(mn1)&"/"&year1
endselect
endselect
}
output of the code attached.