Feld Lips unbekannt

Getting started ... Alles für einen gelungenen Start.
8 Beiträge Seite 1 von 1
8 Beiträge Seite 1 von 1

Feld Lips unbekannt

Beitrag von jonas1996 (ForumUser / 24 / 7 / 0 ) » 24. Apr 2014 11:14

Hallo Community

Ich sollte ein Fromular mit Smart froms erstellten.

Nun habe ich das Problem, dass es mir den Fehler (Feld "LIPS" unbekannt. Es ist weder in einer der angegebenen Tabelle enthalten noch durch eine DATA-Anweisung definiert) auftritt.

Ich denke der Fehler kommt daher das ich per select lips lesen will und in ls_lips schreibe.
Zeile 302
Der Fehler tritt seit der einfügung der Zeilen 302- 310 und 24 auf.
ls_lips ist so typisiert ls_lips type lips
lips habe ich als EIngabeparameter defieniert.

Code: Alles auswählen.

data: lv_AdressTyp type AD_ADRTYPE,

      lv_WERKS TYPE T001W-WERKS,
      LS_IT_ORG like line of IS_DLV_DELNOTE-it_ORG,
      LS_HD_ADR LIKE LINE OF IS_DLV_DELNOTE-HD_ADR,
      LS_HD_ADR2 LIKE LINE OF IS_DLV_DELNOTE-HD_ADR,
      it_tel type table of adtel with header line,
      it_fax type table of adfax WITH HEADER LINE,
      is_name type BAPIADDR3,
      Vorname(30) type c,
      Nachname(30) type c,
      lt_print_name type TABLE OF TY_SZADR_PRINTFORM_LINE,
      it_TEL2 TYPE STANDARD TABLE OF BAPIADTEL WITH HEADER LINE,
      it_FAX2 type STANDARD TABLE OF BAPIADfax WITH HEADER LINE,
      ls_it_GEN type STANDARD TABLE OF LEDLV_IT_GEN with HEADER LINE,
      it_RETURN type STANDARD TABLE OF BAPIRET2,
      ls_vhilm type ty_vhilm,
      ls_betreff type sadr,
      ls_salesorg_adr type ADDR1_SEL,
      ls_firma type sadr,
      ls_lips type lips,
      lv_anzlu type i,
      ls_lips TYPE lips.
break joma.
lv_AdressTyp = '1'.

** Werk aus der ersten Lieferposition lesen
LOOP AT IS_DLV_DELNOTE-IT_ORG
  INTO LS_IT_ORG.
  exit.
ENDLOOP.
*
lv_werks = LS_IT_ORG-plant.
*
SELECT single ADRNR
  FROM T001W
  into gv_AdressNummer
  WHERE WERKS = lv_WERKS .
  clear sy-subrc.
LOOP AT IS_DLV_DELNOTE-HD_ADR
  into LS_HD_ADR
  where partn_role = 'ZT'.

ENDLOOP.
IF sy-subrc <> 0.
LOOP AT IS_DLV_DELNOTE-HD_ADR
  INTO LS_HD_ADR
  where Partn_role = 'SP'.
ENDLOOP.

ENDIF.
*Prüfung ob in partnerrolle 'sp' steht wenn nicht wird
*die Spediteuraddresse nicht gedruckt.
IF ls_hd_adr-partn_role <> 'SP' AND ls_hd_adr-partn_role <> 'ZT'.
GV_DRUCK  = ''.

else.


*addressdaten auslesen
CALL FUNCTION 'ADDRESS_INTO_PRINTFORM'
  EXPORTING
*   ADRSWA_IN                      =
*   ADDRESS_1                      =
*   ADDRESS_2                      =
*   ADDRESS_3                      =
    ADDRESS_TYPE                   = lv_AdressTyp
    ADDRESS_NUMBER                 = LS_HD_ADR-ADDR_NO
*   ADDRESS_HANDLE                 = ' '
*   PERSON_NUMBER                  = ' '
*   PERSON_HANDLE                  = ' '
*   SENDER_COUNTRY                 = ' '
*   RECEIVER_LANGUAGE              = ' '
    NUMBER_OF_LINES                = 1
*   STREET_HAS_PRIORITY            = ' '
*   LINE_PRIORITY                  = ' '
*   COUNTRY_NAME_IN_RECEIVER_LANGU = ' '
*   LANGUAGE_FOR_COUNTRY_NAME      = ' '
*   NO_UPPER_CASE_FOR_CITY         = ' '
*   IV_NATION                      = ' '
*   IV_NATION_SPACE                = ' '
*   IV_PERSON_ABOVE_ORGANIZATION   = ' '
*   IS_BUPA_TIME_DEPENDENCY        = ' '
*   IV_COUNTRY_NAME_SEPARATE_LINE  = ' '
*   IV_LANGU_CREA                  = ' '
*   IV_DISPLAY_COUNTRY_IN_SHRTFORM = ' '
  IMPORTING
*   ADRSWA_OUT                     =
*   ADDRESS_PRINTFORM              =
*   ADDRESS_SHORT_FORM             =
*   ADDRESS_SHORT_FORM_S           =
*   ADDRESS_DATA_CARRIER           =
*   ADDRESS_DATA_CARRIER_0         =
*   NUMBER_OF_USED_LINES           =
*   NAME_IS_EMPTY                  =
*   ADDRESS_NOT_FOUND              =
    ADDRESS_PRINTFORM_TABLE        = lt_print_name
*   ADDRESS_SHORT_FORM_WO_NAME     =
*   EV_NATION                      =
  .
* Zugriff auf 1. zeile
READ TABLE lt_print_name INTO GS_PRINT_NAME INDEX 1.
*TEL auslesen Kunde
CALL FUNCTION 'ADDR_COMM_GET'
  EXPORTING
*   ADDRESS_HANDLE              = ' '
   ADDRESS_NUMBER              = LS_HD_ADR-ADDR_NO
*   DATE_FROM                   = '00010101'
*   LANGUAGE                    = SY-LANGU
    TABLE_TYPE                  = 'ADTEL'
*   IV_CURRENT_STATE            = 'X'
*   IV_FILL_EMPTY_COUNTRY       = 'X'
* IMPORTING
*   RETURNCODE                  =
  TABLES
    COMM_TABLE                  = IT_TEL
*   ERROR_TABLE                 =
*   ET_USAGE                    =
*   ET_USAGE_UUID               =
* EXCEPTIONS
*   PARAMETER_ERROR             = 1
*   ADDRESS_NOT_EXIST           = 2
*   INTERNAL_ERROR              = 3
*   OTHERS                      = 4
.

lv_telNR = it_tel-Telnr_long.
*FAX auslesen Kunde
CALL FUNCTION 'ADDR_COMM_GET'
  EXPORTING
*   ADDRESS_HANDLE              = ' '
   ADDRESS_NUMBER              = LS_HD_ADR-ADDR_NO
*   DATE_FROM                   = '00010101'
*   LANGUAGE                    = SY-LANGU
    TABLE_TYPE                  = 'ADFAX'
*   IV_CURRENT_STATE            = 'X'
*   IV_FILL_EMPTY_COUNTRY       = 'X'
* IMPORTING
*   RETURNCODE                  =
  TABLES
    COMM_TABLE                  = IT_fax.
*   ERROR_TABLE                 =
*   ET_USAGE                    =
*   ET_USAGE_UUID               =
* EXCEPTIONS
*   PARAMETER_ERROR             = 1
*   ADDRESS_NOT_EXIST           = 2
*   INTERNAL_ERROR              = 3
*   OTHERS                      = 4

lv_fax = it_fax-faxnr_long.
ENDIF.
*Tel und Fax des internen users auslesen
CALL FUNCTION 'BAPI_USER_GET_DETAIL'
  EXPORTING
    USERNAME             = sy-uname
*   CACHE_RESULTS        = 'X'
*
 IMPORTING
*   LOGONDATA            =
*   DEFAULTS             =
   ADDRESS              = is_name
*   COMPANY              =
*   SNC                  =
*   REF_USER             =
*   ALIAS                =
*   UCLASS               =
*   LASTMODIFIED         =
*   ISLOCKED             =
*   IDENTITY             =
*   ADMINDATA            =
  TABLES
*   PARAMETER            =
*   PROFILES             =
*   ACTIVITYGROUPS       =
   RETURN               = it_Return
   ADDTEL               = it_TEL2
   ADDFAX               = it_FAX2
*   ADDTTX               =
*   ADDTLX               =
*   ADDSMTP              =
*   ADDRML               =
*   ADDX400              =
*   ADDRFC               =
*   ADDPRT               =
*   ADDSSF               =
*   ADDURI               =
*   ADDPAG               =
*   ADDCOMREM            =
*   PARAMETER1           =
*   GROUPS               =
*   UCLASSSYS            =
*   EXTIDHEAD            =
*   EXTIDPART            =
*   SYSTEMS              =
          .
gv_Vorname = is_name-firstname.
gv_Nachname = is_name-lastname.
gv_tel2 = it_tel2-tel_no.
gv_fax2 = it_fax2-fax.
*Firma auslesen

select name1
  from T001W
  into gv_name
  where werks = lv_werks.
ENDSELECT.
*brutto auslesen und deliv numb.
gv_deliv = is_dlv_delnote-hd_gen-deliv_numb.
call function 'Z_SD_GET_WEIGHT'
  EXPORTING
    VBELN            = gv_deliv
    BEL_TYPE         = 'L'
  IMPORTING
    BRUTTO_GEW       = gv_brutto.
*Brutto wert in c feld speichern und aufbereiten um
*eine richtige formation zu erreichen
write gv_brutto to gv_brutto_char LEFT-JUSTIFIED.
* Bruttoeinheit auslesen
GV_BRUTTO_UNIT = IS_DLV_DELNOTE-HD_GEN-UNIT_OF_WEIGHT.
*Bestellnummer auslesen
GV_BESTELLNR = IS_DLV_DELNOTE-HD_REF-purch_no.
*Anlieferung auslesen
GV_ANLIEFERUNG = IS_DLV_DELNOTE-HD_GEN-DLV_DATE.
*Entladestelle auselesen
LOOP AT IS_DLV_DELNOTE-HD_ADR
  INTO LS_HD_ADR2
  where Partn_role = 'WE'.
ENDLOOP.
gv_adr_we = LS_HD_ADR2-Addr_no.


LOOP AT is_dlv_delnote-it_gen
  INTO ls_it_gen
  where matl_type = 'GEBI'.
ls_vhilm-palbez = ls_it_gen-SHORT_TEXT.
ls_vhilm-palmng = ls_it_gen-DLV_QTY_STOCK.
ls_vhilm-palmeinh = ls_it_gen-BASE_UOM.

append ls_vhilm to gt_vhilm.

ENDLOOP.
GV_ADR_WE2-ADDRNUMBER = GV_ADR_we.
CALL FUNCTION 'ADDR_GET'
  EXPORTING
    ADDRESS_SELECTION             = GV_ADR_WE2
*   ADDRESS_GROUP                 =
*   READ_SADR_ONLY                = ' '
*   READ_TEXTS                    = ' '
*   IV_CURRENT_COMM_DATA          = ' '
 IMPORTING
*  ADDRESS_VALUE                 =
*   ADDRESS_ADDITIONAL_INFO       =
*   RETURNCODE                    =
*   ADDRESS_TEXT                  =
   SADR                          = ls_betreff
* TABLES
*   ADDRESS_GROUPS                =
*   ERROR_TABLE                   =
*   VERSIONS                      =
 EXCEPTIONS
   PARAMETER_ERROR               = 1
   ADDRESS_NOT_EXIST             = 2
   VERSION_NOT_EXIST             = 3
   INTERNAL_ERROR                = 4
   OTHERS                        = 5
          .
IF SY-SUBRC <> 0.
* Implement suitable error handling here
ENDIF.
gv_betreff = ls_betreff-ort01.
IF IS_DLV_DELNOTE-HD_ORG-SHIP_POINT = 915.
  gv_abholung = 'Abholung mit Zufall besprechen'.
  ls_salesorg_adr-ADDRNUMBER = IS_DLV_DELNOTE-HD_ORG-salesorg_adr.
  CALL FUNCTION 'ADDR_GET'
  EXPORTING
    ADDRESS_SELECTION             = ls_salesorg_adr
*   ADDRESS_GROUP                 =
*   READ_SADR_ONLY                = ' '
*   READ_TEXTS                    = ' '
*   IV_CURRENT_COMM_DATA          = ' '
 IMPORTING
*   ADDRESS_VALUE                 =
*   ADDRESS_ADDITIONAL_INFO       =
*   RETURNCODE                    =
*   ADDRESS_TEXT                  =
   SADR                          =  ls_firma
* TABLES
*   ADDRESS_GROUPS                =
*   ERROR_TABLE                   =
*   VERSIONS                      =
 EXCEPTIONS
   PARAMETER_ERROR               = 1
   ADDRESS_NOT_EXIST             = 2
   VERSION_NOT_EXIST             = 3
   INTERNAL_ERROR                = 4
   OTHERS                        = 5
          .
  gv_name = ls_firma-name1.
ENDIF.
SELECT * from lips
 INTO ls_lips
where lips-bwart <> SPACE and
        LIPS-UECHA = SPACE.
IF lips-vrkme <> LU.
lv_anzlu = ls_Lips-lfimg * ls_lips-UMVKZ.
ENDIF.

ENDSELECT.
  
Wahrseinlich ist es ein für die meisten von euch logischer Fehler leider komme ich einfach nicht drauf an was es liegen könnte.

hoffe auf eine schnelle Antwort

Gruss
Jonas Marxer
IT Lehrling


Re: Feld Lips unbekannt

Beitrag von Alexander D. (Expert / 670 / 27 / 81 ) » 24. Apr 2014 11:42

hi,

schuld wird die Stelle IF lips-vrkme <> LU. sein. Du liest vorher die Werte aus LIPS in ls_lips, versuchst dann aber doch wieder auf LIPS zuzugreifen. Richtig wäre also

Code: Alles auswählen.

SELECT * from lips
 INTO ls_lips
where lips-bwart <> SPACE and
        LIPS-UECHA = SPACE.
IF ls_lips-vrkme <> 'LU'.
lv_anzlu = ls_Lips-lfimg * ls_lips-UMVKZ.
ENDIF.
LU müsste dabei meiner Meinung mit Hochkomma geschrieben werden
schöne Grüße
Alexander

ECC 6.0 EHP 7

Re: Feld Lips unbekannt

Beitrag von jonas1996 (ForumUser / 24 / 7 / 0 ) » 24. Apr 2014 12:09

Habe dies so angepasst.
Bekomme immernoch den selben Fehler.

Code: Alles auswählen.

data: lv_AdressTyp type AD_ADRTYPE,

      lv_WERKS TYPE T001W-WERKS,
      LS_IT_ORG like line of IS_DLV_DELNOTE-it_ORG,
      LS_HD_ADR LIKE LINE OF IS_DLV_DELNOTE-HD_ADR,
      LS_HD_ADR2 LIKE LINE OF IS_DLV_DELNOTE-HD_ADR,
      it_tel type table of adtel with header line,
      it_fax type table of adfax WITH HEADER LINE,
      is_name type BAPIADDR3,
      Vorname(30) type c,
      Nachname(30) type c,
      lt_print_name type TABLE OF TY_SZADR_PRINTFORM_LINE,
      it_TEL2 TYPE STANDARD TABLE OF BAPIADTEL WITH HEADER LINE,
      it_FAX2 type STANDARD TABLE OF BAPIADfax WITH HEADER LINE,
      ls_it_GEN type STANDARD TABLE OF LEDLV_IT_GEN with HEADER LINE,
      it_RETURN type STANDARD TABLE OF BAPIRET2,
      ls_vhilm type ty_vhilm,
      ls_betreff type sadr,
      ls_salesorg_adr type ADDR1_SEL,
      ls_firma type sadr,
      ls_lips type lips,
      lv_anzlu type i,
      ls_lips TYPE lips.
break joma.
lv_AdressTyp = '1'.

** Werk aus der ersten Lieferposition lesen
LOOP AT IS_DLV_DELNOTE-IT_ORG
  INTO LS_IT_ORG.
  exit.
ENDLOOP.
*
lv_werks = LS_IT_ORG-plant.
*
SELECT single ADRNR
  FROM T001W
  into gv_AdressNummer
  WHERE WERKS = lv_WERKS .
  clear sy-subrc.
LOOP AT IS_DLV_DELNOTE-HD_ADR
  into LS_HD_ADR
  where partn_role = 'ZT'.

ENDLOOP.
IF sy-subrc <> 0.
LOOP AT IS_DLV_DELNOTE-HD_ADR
  INTO LS_HD_ADR
  where Partn_role = 'SP'.
ENDLOOP.

ENDIF.
*Prüfung ob in partnerrolle 'sp' steht wenn nicht wird
*die Spediteuraddresse nicht gedruckt.
IF ls_hd_adr-partn_role <> 'SP' AND ls_hd_adr-partn_role <> 'ZT'.
GV_DRUCK  = ''.

else.


*addressdaten auslesen
CALL FUNCTION 'ADDRESS_INTO_PRINTFORM'
  EXPORTING
*   ADRSWA_IN                      =
*   ADDRESS_1                      =
*   ADDRESS_2                      =
*   ADDRESS_3                      =
    ADDRESS_TYPE                   = lv_AdressTyp
    ADDRESS_NUMBER                 = LS_HD_ADR-ADDR_NO
*   ADDRESS_HANDLE                 = ' '
*   PERSON_NUMBER                  = ' '
*   PERSON_HANDLE                  = ' '
*   SENDER_COUNTRY                 = ' '
*   RECEIVER_LANGUAGE              = ' '
    NUMBER_OF_LINES                = 1
*   STREET_HAS_PRIORITY            = ' '
*   LINE_PRIORITY                  = ' '
*   COUNTRY_NAME_IN_RECEIVER_LANGU = ' '
*   LANGUAGE_FOR_COUNTRY_NAME      = ' '
*   NO_UPPER_CASE_FOR_CITY         = ' '
*   IV_NATION                      = ' '
*   IV_NATION_SPACE                = ' '
*   IV_PERSON_ABOVE_ORGANIZATION   = ' '
*   IS_BUPA_TIME_DEPENDENCY        = ' '
*   IV_COUNTRY_NAME_SEPARATE_LINE  = ' '
*   IV_LANGU_CREA                  = ' '
*   IV_DISPLAY_COUNTRY_IN_SHRTFORM = ' '
  IMPORTING
*   ADRSWA_OUT                     =
*   ADDRESS_PRINTFORM              =
*   ADDRESS_SHORT_FORM             =
*   ADDRESS_SHORT_FORM_S           =
*   ADDRESS_DATA_CARRIER           =
*   ADDRESS_DATA_CARRIER_0         =
*   NUMBER_OF_USED_LINES           =
*   NAME_IS_EMPTY                  =
*   ADDRESS_NOT_FOUND              =
    ADDRESS_PRINTFORM_TABLE        = lt_print_name
*   ADDRESS_SHORT_FORM_WO_NAME     =
*   EV_NATION                      =
  .
* Zugriff auf 1. zeile
READ TABLE lt_print_name INTO GS_PRINT_NAME INDEX 1.
*TEL auslesen Kunde
CALL FUNCTION 'ADDR_COMM_GET'
  EXPORTING
*   ADDRESS_HANDLE              = ' '
   ADDRESS_NUMBER              = LS_HD_ADR-ADDR_NO
*   DATE_FROM                   = '00010101'
*   LANGUAGE                    = SY-LANGU
    TABLE_TYPE                  = 'ADTEL'
*   IV_CURRENT_STATE            = 'X'
*   IV_FILL_EMPTY_COUNTRY       = 'X'
* IMPORTING
*   RETURNCODE                  =
  TABLES
    COMM_TABLE                  = IT_TEL
*   ERROR_TABLE                 =
*   ET_USAGE                    =
*   ET_USAGE_UUID               =
* EXCEPTIONS
*   PARAMETER_ERROR             = 1
*   ADDRESS_NOT_EXIST           = 2
*   INTERNAL_ERROR              = 3
*   OTHERS                      = 4
.

lv_telNR = it_tel-Telnr_long.
*FAX auslesen Kunde
CALL FUNCTION 'ADDR_COMM_GET'
  EXPORTING
*   ADDRESS_HANDLE              = ' '
   ADDRESS_NUMBER              = LS_HD_ADR-ADDR_NO
*   DATE_FROM                   = '00010101'
*   LANGUAGE                    = SY-LANGU
    TABLE_TYPE                  = 'ADFAX'
*   IV_CURRENT_STATE            = 'X'
*   IV_FILL_EMPTY_COUNTRY       = 'X'
* IMPORTING
*   RETURNCODE                  =
  TABLES
    COMM_TABLE                  = IT_fax.
*   ERROR_TABLE                 =
*   ET_USAGE                    =
*   ET_USAGE_UUID               =
* EXCEPTIONS
*   PARAMETER_ERROR             = 1
*   ADDRESS_NOT_EXIST           = 2
*   INTERNAL_ERROR              = 3
*   OTHERS                      = 4

lv_fax = it_fax-faxnr_long.
ENDIF.
*Tel und Fax des internen users auslesen
CALL FUNCTION 'BAPI_USER_GET_DETAIL'
  EXPORTING
    USERNAME             = sy-uname
*   CACHE_RESULTS        = 'X'
*
 IMPORTING
*   LOGONDATA            =
*   DEFAULTS             =
   ADDRESS              = is_name
*   COMPANY              =
*   SNC                  =
*   REF_USER             =
*   ALIAS                =
*   UCLASS               =
*   LASTMODIFIED         =
*   ISLOCKED             =
*   IDENTITY             =
*   ADMINDATA            =
  TABLES
*   PARAMETER            =
*   PROFILES             =
*   ACTIVITYGROUPS       =
   RETURN               = it_Return
   ADDTEL               = it_TEL2
   ADDFAX               = it_FAX2
*   ADDTTX               =
*   ADDTLX               =
*   ADDSMTP              =
*   ADDRML               =
*   ADDX400              =
*   ADDRFC               =
*   ADDPRT               =
*   ADDSSF               =
*   ADDURI               =
*   ADDPAG               =
*   ADDCOMREM            =
*   PARAMETER1           =
*   GROUPS               =
*   UCLASSSYS            =
*   EXTIDHEAD            =
*   EXTIDPART            =
*   SYSTEMS              =
          .
gv_Vorname = is_name-firstname.
gv_Nachname = is_name-lastname.
gv_tel2 = it_tel2-tel_no.
gv_fax2 = it_fax2-fax.
*Firma auslesen

select name1
  from T001W
  into gv_name
  where werks = lv_werks.
ENDSELECT.
*brutto auslesen und deliv numb.
gv_deliv = is_dlv_delnote-hd_gen-deliv_numb.
call function 'Z_SD_GET_WEIGHT'
  EXPORTING
    VBELN            = gv_deliv
    BEL_TYPE         = 'L'
  IMPORTING
    BRUTTO_GEW       = gv_brutto.
*Brutto wert in c feld speichern und aufbereiten um
*eine richtige formation zu erreichen
write gv_brutto to gv_brutto_char LEFT-JUSTIFIED.
* Bruttoeinheit auslesen
GV_BRUTTO_UNIT = IS_DLV_DELNOTE-HD_GEN-UNIT_OF_WEIGHT.
*Bestellnummer auslesen
GV_BESTELLNR = IS_DLV_DELNOTE-HD_REF-purch_no.
*Anlieferung auslesen
GV_ANLIEFERUNG = IS_DLV_DELNOTE-HD_GEN-DLV_DATE.
*Entladestelle auselesen
LOOP AT IS_DLV_DELNOTE-HD_ADR
  INTO LS_HD_ADR2
  where Partn_role = 'WE'.
ENDLOOP.
gv_adr_we = LS_HD_ADR2-Addr_no.


LOOP AT is_dlv_delnote-it_gen
  INTO ls_it_gen
  where matl_type = 'GEBI'.
ls_vhilm-palbez = ls_it_gen-SHORT_TEXT.
ls_vhilm-palmng = ls_it_gen-DLV_QTY_STOCK.
ls_vhilm-palmeinh = ls_it_gen-BASE_UOM.

append ls_vhilm to gt_vhilm.

ENDLOOP.
GV_ADR_WE2-ADDRNUMBER = GV_ADR_we.
CALL FUNCTION 'ADDR_GET'
  EXPORTING
    ADDRESS_SELECTION             = GV_ADR_WE2
*   ADDRESS_GROUP                 =
*   READ_SADR_ONLY                = ' '
*   READ_TEXTS                    = ' '
*   IV_CURRENT_COMM_DATA          = ' '
 IMPORTING
*  ADDRESS_VALUE                 =
*   ADDRESS_ADDITIONAL_INFO       =
*   RETURNCODE                    =
*   ADDRESS_TEXT                  =
   SADR                          = ls_betreff
* TABLES
*   ADDRESS_GROUPS                =
*   ERROR_TABLE                   =
*   VERSIONS                      =
 EXCEPTIONS
   PARAMETER_ERROR               = 1
   ADDRESS_NOT_EXIST             = 2
   VERSION_NOT_EXIST             = 3
   INTERNAL_ERROR                = 4
   OTHERS                        = 5
          .
IF SY-SUBRC <> 0.
* Implement suitable error handling here
ENDIF.
gv_betreff = ls_betreff-ort01.
IF IS_DLV_DELNOTE-HD_ORG-SHIP_POINT = 915.
  gv_abholung = 'Abholung mit Zufall besprechen'.
  ls_salesorg_adr-ADDRNUMBER = IS_DLV_DELNOTE-HD_ORG-salesorg_adr.
  CALL FUNCTION 'ADDR_GET'
  EXPORTING
    ADDRESS_SELECTION             = ls_salesorg_adr
*   ADDRESS_GROUP                 =
*   READ_SADR_ONLY                = ' '
*   READ_TEXTS                    = ' '
*   IV_CURRENT_COMM_DATA          = ' '
 IMPORTING
*   ADDRESS_VALUE                 =
*   ADDRESS_ADDITIONAL_INFO       =
*   RETURNCODE                    =
*   ADDRESS_TEXT                  =
   SADR                          =  ls_firma
* TABLES
*   ADDRESS_GROUPS                =
*   ERROR_TABLE                   =
*   VERSIONS                      =
 EXCEPTIONS
   PARAMETER_ERROR               = 1
   ADDRESS_NOT_EXIST             = 2
   VERSION_NOT_EXIST             = 3
   INTERNAL_ERROR                = 4
   OTHERS                        = 5
          .
  gv_name = ls_firma-name1.
ENDIF.
SELECT * from lips
 INTO ls_lips
where lips-bwart <> SPACE and
        LIPS-UECHA = SPACE.
IF ls_lips-vrkme <> 'LU'.
lv_anzlu = ls_Lips-lfimg * ls_lips-UMVKZ.
ENDIF.

ENDSELECT.
  

Re: Feld Lips unbekannt

Beitrag von a-dead-trousers (Top Expert / 3217 / 81 / 799 ) » 24. Apr 2014 12:26

Code: Alles auswählen.

where lips-bwart <> SPACE and LIPS-UECHA = SPACE.
muss

Code: Alles auswählen.

where lips~bwart <> SPACE and LIPS~UECHA = SPACE.
lauten.

Statt - ein ~
Theory is when you know something, but it doesn't work.
Practice is when something works, but you don't know why.
Programmers combine theory and practice: Nothing works and they don't know why.

ECC: 6.07
Basis: 7.40

Re: Feld Lips unbekannt

Beitrag von jonas1996 (ForumUser / 24 / 7 / 0 ) » 24. Apr 2014 12:53

Habe es so angepasst bekomme immer noch den selben Fehler.
Wieso ~ habe bis jetzt immer - benutzt und hat so auch immer funktioniert.

Re: Feld Lips unbekannt

Beitrag von Alexander D. (Expert / 670 / 27 / 81 ) » 24. Apr 2014 13:31

ok, ich habe es vorhin auf die schnelle geschrieben, hätte vielleicht noch etwas genauer drüber schauen sollen.

was die Tilde (~) angeht, so würde ich adt widersprechen. Diese benötigst du bei einem Join, in diesem Fall machst du ja nur ein Select. Die Angabe der Tabelle in der Where-Bedingung in deinem Code ist überflüssig. Du selektierst ja von der LIPS, es reicht dann bei WHERE die Feldnamen aufzuzählen:

Code: Alles auswählen.

SELECT * from lips
     INTO ls_lips
    where bwart <> SPACE and UECHA = SPACE.

    IF ls_lips-vrkme <> 'LU'.
    lv_anzlu = ls_Lips-lfimg * ls_lips-UMVKZ.
    ENDIF.

    ENDSELECT.
sollte es immer noch nicht klappen, so poste bitte noch mal den aktuellen Code und gib bitte mit an in welcher Zeile der Fehler auftritt
schöne Grüße
Alexander

ECC 6.0 EHP 7

Re: Feld Lips unbekannt

Beitrag von Alexander D. (Expert / 670 / 27 / 81 ) » 24. Apr 2014 14:19

und noch ein Nachtrag: die Logik des Selects auf die LIPS kann noch nicht ganz stimmen. So wie es zur Zeit aufgebaut ist würdest du zwar nahezu die komplette LIPS lesen, in der Variablen lv_anzlu aber nur den Wert zu dem letzten Datensatz aus der Lips haben, welcher den Bedingungen entspricht.
schöne Grüße
Alexander

ECC 6.0 EHP 7

Re: Feld Lips unbekannt

Beitrag von a-dead-trousers (Top Expert / 3217 / 81 / 799 ) » 24. Apr 2014 14:42

Alexander D. hat geschrieben:was die Tilde (~) angeht, so würde ich adt widersprechen. Diese benötigst du bei einem Join, in diesem Fall machst du ja nur ein Select.
Da geb ich dir sogar recht. Grundsätzlich ist es aber kein Fehler die ~ auch ohne join zu verwenden. Ich wollte nur die falsche Syntax an der Stelle verdeutlichen und warum die Fehlermeldung auf das Feld mit dem Namen LIPS lautet obwohl es das eigentlich gar nicht im Programm gibt.
Alexander D. hat geschrieben:sollte es immer noch nicht klappen, so poste bitte noch mal den aktuellen Code und gib bitte mit an in welcher Zeile der Fehler auftritt
Meine Vermutung war auch schon, dass sich die Zeilennummer in der Fehlermeldung nach dem ersten Änderungsvorschlag verschoben haben dürfte.
Also bitte ergänzen falls der Fehler nach wie vor auftreten sollte.

lg ADT
Theory is when you know something, but it doesn't work.
Practice is when something works, but you don't know why.
Programmers combine theory and practice: Nothing works and they don't know why.

ECC: 6.07
Basis: 7.40

Seite 1 von 1

Aktuelle Forenbeiträge

Langtext zur Exception
vor 41 Minuten von a-dead-trousers 11 / 96
Adobe LiveCycle Designer - Ausblenden Text auf letzter Seite
vor 2 Stunden von a-dead-trousers 4 / 91
Welche Entwicklertools?
vor 17 Stunden von LostDarkness 2 / 920
Werksspezifische Konfiguration kopieren
vor 19 Stunden von eleve 2 / 48
Removal of left space - next to a docking container
vor 19 Stunden von Haemma83 16 / 114

Unbeantwortete Forenbeiträge

BAPI_PO_CREATE1 und Einkaufsinfosatz
vor 3 Tagen von SweetRuedi 1 / 81
WCOCO: Gruppe für Betragsfelder 0S01
vor 5 Tagen von SAP_ENTWICKLER 1 / 52
CAS-Nr.: Chemical Abstracs Service
vor einer Woche von SAP_ENTWICKLER 1 / 92
Interaktives Skript, Rolle IC-Manager
vor 3 Wochen von erubadhron86 1 / 129