Help needed on Error number (12383)

Hobby

New Member
Hai,

I am facing a problem.
i was compiling the following piece of code

def new shared temp-table tt-temp like hoteldsc.
def new shared dataset d-date for tt-temp.

but i got the error

Buffer tt-temp in shared dataset d-date must be shared too. (12383)
** Could not understand line 2. (196)

This seems to be kinda not correct because i had define tt-temp as shared only.
Can anyone please help on this.
 
You may find this disturbing - but:

The ProDataSet definition requires a buffer and not a temp-table. Your definition declares the temp-table as shared, but that does not make the default buffer associated with the temp-table shared. Therefore you need to define a shared buffer which you must use in the definition of the ProDataSet.

def new shared temp-table tt-temp like hoteldsc.
def new shared buffer b_tt-temp for tt-temp.
def new shared dataset d-date for b_tt-temp.
Having said that I would strongly recommend you to not use shared "things" as it is not good programming practice. Instead you should pass this "things" as parameters.

HTH, RealHeavyDude.
 
Or, better yet, encapsulate the TT in a procedure/object and manipulate it with methods.
 
Thank you RealHeavyDude,Thank you tamhas for your help.I tried with shared buffer and it worked. my intention is to pass the data to a generic routine,which is getting called by lot of programs,so changing the paramter is a big work for me.
 
Back
Top