Ask a Question related to Coldfusion Database Access, Design and Development.
-
cld007 #1
E-mail with apostrophe
I have this weird situation happening when someone's e-mail address is captured
from a form; if the e-mail address contains an apostrophe (single quote like
M.O'Brian@acme.com), the saved information will be M.O''Brian@acme.com.... and
if you save it again it will become M.O'''Brian@acme.com Another quote is
added everytime the data is saved again.
Can anyone provide me with a clue or a lead as to what I should be looking for
that could be causing this situation?
The same thing happens in any text field (Name, Address, City, etc).
Environment:
CFMX7-Standard
DB: Paradox 9
Connection: ODBC Socket using Intersolv 3.11 ODBC DSN
See below code for actual CFQuery. I also tried single quote to surroud text
field in the Insert statement but no change.
Thanks,
Claude
<CFQUERY DATASOURCE="#ds#" >
INSERT INTO table VALUES( #max_key.new_key#,
"#form.lname#",
"#form.fname#",
"#form.phone#",
"#form.fax#",
"#form.email#",
"#form.address1#",
"#form.address2#",
"#form.address3#",
"#form.city#",
"#form.prov_code#",
"#form.postal_code#"
)
</cfquery>
cld007 Guest
-
PHP and the apostrophe (')
Hello to all, I'm a beginner with PHP and MySQL. Aktually I have some forms to update MySQL tables. Every think work well, but I have a problem... -
apostrophe madness
Hello everyone. I am TOTALLY baffled. PLEASE, I need some help here. In the event that one must deal with a name including an apostrophe...I... -
Apostrophe replaced by ? marks
I ran into a similar problem recently and this was the solution suggested (which solved my problem): documents by some word processors. If you... -
Display Apostrophe problem ??
Hi I am in need of the urgent solution from all the Flash Experts. I am passing the string in the Flash through C# using XML. In the Flash I... -
Apostrophe in a string
I'm new to SQL Server programming (I've been using Access) and wanted to know: How do I put an apostrophe in a string, if the apostrophe is the... -
BKBK #2
Re: E-mail with apostrophe (single quote)
I have no experience with Paradox 9. However, it appears to be "escaping" the
single-quote character automatically.
A solution might be to return to single-quotes for text fields in the
insert-statement, as that is standard, and to use the function
preservesinglequotes, i.e.
INSERT INTO table VALUES(#max_key.new_key#, '#form.lname#', '#form.fname#',
'#form.phone#','#form.fax','#preservesinglequotes( form.email)#','#form.address1#
',... etc.)
BKBK Guest
-
cld007 #3
Re: E-mail with apostrophe (single quote)
This is great! I was not aware of this function. I just tried it out and it does exactly what its name implies!
Thank you VERY MUCH!
Claude
cld007 Guest



Reply With Quote

