Page 1 of 1

Is their something here that I never knew?

Posted: Mon Apr 06, 2009 2:27 pm
by BDKR
I'm inserting a string into a varchar field. That string is essentially numbers that are delimited with a ":". Is there something about using this that I don't know about? The reason for my asking being that even though the query succeeds, this field always comes back empty.

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 3:28 pm
by Christopher
Are you sure the insert is actually succeeding?

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 4:08 pm
by greyhoundcode
Proper use of quotes within the query?

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 4:13 pm
by John Cartwright
Also try to echo the query out before sending it to the database, as arborint suggested, it might not be what you think.

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 5:06 pm
by BDKR
arborint wrote:Are you sure the insert is actually succeeding?

Yeah, I'm sure. :wink:

Oh well. I'll keep :banghead: for now. I actually have another solution that I'll work on for the short term.

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 5:38 pm
by jayshields
Post the exact query being sent to MySQL.

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 5:40 pm
by Christopher
BDKR wrote:
arborint wrote:Are you sure the insert is actually succeeding?

Yeah, I'm sure. :wink:
I guess I am not clear on what "this field always comes back empty" means. The INSERT will not return any data. Are you saying that later SELECTing the record return an empty field?

Re: Is their something here that I never knew?

Posted: Mon Apr 06, 2009 5:54 pm
by BDKR
arborint wrote:
BDKR wrote:
arborint wrote:Are you sure the insert is actually succeeding?

Yeah, I'm sure. :wink:
I guess I am not clear on what "this field always comes back empty" means. The INSERT will not return any data. Are you saying that later SELECTing the record return an empty field?
My bad. It's not an INSERT. It's a SELECT.