I'm pretty sure I did post it. Lemme just simplify it; I'm trying to convert certain strings to a SQL REPLACE INTO entry.
So I using the full script, I place this in a textarea:
1,Test,Test,,,,,,,,,,,,,,,,,{ Testing {} Test { } { } { } }{{ } },{ test{} finaltest{ } {{}{ }{ }{}{} again{} },{finaltest{ } {{}{ }{ }{}{} again{}}
1,Test,Test,,,,,,,,,,,,,,,,,{ Testing {} Test { } { } { } }{{ } },{ test{} finaltest{ } {{}{ }{ }{}{} again{} },{finaltest{ } {{}{ }{ }{}{} again{}}
Nothing too unusual there. I was expecting the outcome to remove the ,{ and }, AND the last } at the end of each line; or replace them with ' at least.
Which should supply this SQL query:
REPLACE INTO file VALUES ('1','Test','Test',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Testing {} Test { } { } { } }{{ }','test{} finaltest{ } {{}{ }{ }{}{} again{}','finaltest{ {{}{ }{ }{}{} again{}');
REPLACE INTO file VALUES ('1','Test','Test',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Testing {} Test { } { } { } }{{ }','test{} finaltest{ } {{}{ }{ }{}{} again{}','finaltest{ {{}{ }{ }{}{} again{}');
But instead, I received:
REPLACE INTO file VALUES ('1','Test','Test',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Testing {} Test { } { } { } }{{ }','test{} finaltest{ } {{}{ }{ }{}{} again{}','finaltest{ {{}{ }{ }{}{} again{}}'); <----- It didn't remove the last } at the end of the string.
REPLACE INTO file VALUES ('1','Test','Test',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Testing {} Test { } { } { } }{{ }','test{} finaltest{ } {{}{ }{ }{}{} again{}','finaltest{ {{}{ }{ }{}{} again{}');
To add to it, the first } in the last ,{ } brace is removed; another problem. Meaning:
finaltest{ } {{}{ }{ }{}{} again{}
became:
finaltest{ {{}{ }{ }{}{} again{}} and finaltest{ {{}{ }{ }{}{} again{}