Hey guys.

I know this is more of an sql problem but I didnt know where else to put it :S

I have an application which stores a UNC path in a mysql database table. However it doest store it correctly for example:

I want to store the UNC Path: \\testmachine\test\

when i look at the table in the database i have the following

\testmachinetest :s

Can anyone explain why this happens? I have the column for the unc path as a VARCHAR(100) is this wrong?

Please help :)

Recommended Answers

All 2 Replies

Member Avatar for iamthwee

show us your code...

Sorry for the late reply, Ive had no Internet for the past week :S

Well I figured out why I couldnt store UNC paths in the base, In mySql "\\" is reserverd as a something else.

If you want to store a UNC path such as "\\test\test\" you need to enter this into your db

"set sql_mode='NO_BACKSLASH_ESCAPES';"

Hope this helps other ppl :D

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.