Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 problem with SQl server data insert

Author  Topic 

useem
Starting Member

1 Post

Posted - 2011-05-25 : 18:39:28
I am inserting data to SQL server DB, I process the values from a string.
when i look on the DB, i can find a weired characters. enclosed an image, someone can tell me how can i remove this characters?

Thanks
useem

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2011-05-25 : 18:53:48
Are you sure these are "weird" characters? Likely these are just unicode characters that your client tool isn't properly displaying. What's the data type of the keyword column? And does your application support multiple languages?

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

jfarrugia
Yak Posting Veteran

55 Posts

Posted - 2011-05-26 : 04:20:32
can you give us further info pls? Maybe code snippet where the insert is occurring?

I suggest placing a TRIM in stored procedure if you're using an SP to insert, else go to application and place a TRIM in T-SQL insert or a trim in other code you're using.

Where software development knowledge meets the reader
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2011-05-26 : 12:51:00
How will TRIM help with these characters? RTRIM/LTRIM are for trailing and leading spaces, not for the type of data seen in the OP's image.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2011-05-30 : 06:39:47
I guess they might be a new line, tab, etc characters

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -