Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

remove quotation mark

Former Member
0 Kudos

I am using LSMW to upload material. Text file are tab delimited with material code and description. If description contains comma, uploaded data has quotation marks enclosed. That is [description, one] become ["description, one"].

Can I remove the quotation marks in LSMW project?

4 REPLIES 4

Former Member
0 Kudos

You Can do it through the Coding. Go to the field in the field Mapping of LSMW. There you can select the field and give the rule for that. It will take you to the Sapscript type editor (Line Editor). There you can write the ABAP code for that field. You Can remove the quotes there by simple String Operations.

Replace quote with space in v_description.

condense v_description.

Regards,

Aman

Former Member
0 Kudos

Hi,

You can remove the Quotation mark for a field, Just goto that field and Double click that field, then the line editor will come, then just write the code in that one to remove the Comma or remove the Quotion, you can write the code here to move the same

Regards

Sudheer

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

Or you can use the TRANSLATE statement.

Translate lv_var using '" '.
condense LV_VAR.

This will take care of all occurances of the ".

Regards,

Rich Heilman

0 Kudos

As an additional follow up to this question I have tried everything you have suggested and I still can't seem to replace the quotation marks. I know I'm getting the quotation marks because my data has a coma in it, so for example it is Gagnon,Annette and it will show up at "Gagnon,Annette". To make matters worse I'm really really new in this world and I also have an if statement in this wonderful converting attempt. This was my final attempt of about 20 different ones I found online...

if not CUSTOMER-NAME1 is initial.

XD02-NAME1 = CUSTOMER-NAME1.

endif.

REPLACE ALL OCCURENCES OF '"' in CUSTOMER-NAME1 with ` `.

CONDENSE CUSTOMER-NAME1.

Any suggestions? What am I missing?

Thank you so much!

Annette

Nevermind... somehow asking for help made it work.... thanks anyways!

Edited by: Annette Gagnon on Aug 9, 2010 11:23 PM

Edited by: Annette Gagnon on Aug 9, 2010 11:45 PM