Rodolfo Montiel Rivera
06/08/08, 13:59:45
Saludos!!
Tengo el siguiente codigo para un select donde el where es dinamico sin en cambio el unico problema es que me marca error de sintaxis en los del move ' ' .
data: r_cond(80) type c.
data: begin of itab_where occurs 0,
cond(80) type c,
end of itab_where.
move: '( kunnr GE so_kunnr-low AND kunnr LE so_kunnr-high )' to r_cond.
perform llena_where using r_cond.
move: 'AND bsid-bukrs EQ '4600' ' into r_cond. <---aqui marca
perform llena_where using r_cond.
move: 'AND bsid-avgbl EQ SPACE' to r_cond.
perform llena_where using r_cond.
move: 'AND ( blart EQ 'dr' OR blart EQ 'rv' ) ' to r_cond. <---aqui marca
perform llena_where using r_cond.
move: 'AND shkzg EQ 's'. ' to r_cond.
perform llena_where using r_cond.
select belnr zuonr budat blart dmbtr
into corresponding fields of itab_reporte
from bsid
where ( itab_where ).
endselect.
endif.
*&---------------------------------------------------------------------*
*& Form llena_where
*&---------------------------------------------------------------------*
form llena_where using r_cond.
move: r_cond to itab_where-cond.
append itab_where.
endform. " llena_where
Tengo el siguiente codigo para un select donde el where es dinamico sin en cambio el unico problema es que me marca error de sintaxis en los del move ' ' .
data: r_cond(80) type c.
data: begin of itab_where occurs 0,
cond(80) type c,
end of itab_where.
move: '( kunnr GE so_kunnr-low AND kunnr LE so_kunnr-high )' to r_cond.
perform llena_where using r_cond.
move: 'AND bsid-bukrs EQ '4600' ' into r_cond. <---aqui marca
perform llena_where using r_cond.
move: 'AND bsid-avgbl EQ SPACE' to r_cond.
perform llena_where using r_cond.
move: 'AND ( blart EQ 'dr' OR blart EQ 'rv' ) ' to r_cond. <---aqui marca
perform llena_where using r_cond.
move: 'AND shkzg EQ 's'. ' to r_cond.
perform llena_where using r_cond.
select belnr zuonr budat blart dmbtr
into corresponding fields of itab_reporte
from bsid
where ( itab_where ).
endselect.
endif.
*&---------------------------------------------------------------------*
*& Form llena_where
*&---------------------------------------------------------------------*
form llena_where using r_cond.
move: r_cond to itab_where-cond.
append itab_where.
endform. " llena_where