0

hi!

I have a table which contain files paths.
my problem is, that when I insert a path, MySQL omit the separator char.

for example:
INSERT INTO A VALUES ('C:\qqq\www\eee.ttt');

will be saved in A as: C:qqqwwweee.ttt

what can I do for saving the path as it is?

(ofcourse, I mean solution withou duplicating the '\',)

I have to say, that there is another problem, for example c:\nate. mysql turn the \n to new line...

Thanks,
Nate

Edited by neti1987: n/a

2
Contributors
3
Replies
4
Views
7 Years
Discussion Span
Last Post by tyson.crouch
0

what you can do is this;

INSERT INTO a VALUES ('C:\\qqq\\www\\eee.ttt');

The first slash tells the MySQL engine that the next character is to be taken as a literal character as opposed to a character which MySQL has reserved.


The second problem can be solved with the same solution.

INSERT INTO a VALUES ('C:\\nate');

Edited by tyson.crouch: n/a

0

what you can do is this;

INSERT INTO a VALUES ('C:\\qqq\\www\\eee.ttt');

The first slash tells the MySQL engine that the next character is to be taken as a literal character as opposed to a character which MySQL has reserved.


The second problem can be solved with the same solution.

INSERT INTO a VALUES ('C:\\nate');

knew that... as I already wrote, I wanna know if there is any other solution.

Thanks anyway...
-Nate

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.