由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Database版 - SQL-Help!
相关主题
Special character in insert valuesHow to insert a string into table? Thanks
JDBC<======================>Oracle8i请教一个sql server的问题
Set autocommit offhow to include record deleted date into trigger?
请教一个有关SQL concat的问题How to insert CURRENT TIMESTAMP into sql
Problem when using SQL " Insert...." to AutoNumber.一个JDBC的问题,希望大家指教!
MS T-SQL 问题[转载] Can anyone interpret this simple SQL?
[转载] ASP问题: Operation must use an updateable query今典问题: 这个Self Query咋写?
问一个可能看起来很怪的问题Access门外汉问题求教
相关话题的讨论汇总
话题: user话题: sql话题: input话题: mytable
进入Database版参与讨论
1 (共1页)
b*******r
发帖数: 6
1
土问题:
INSERT INTO MyTable (PriKey, Description) VALUES (user_input_key,
user_input_description)
被写成了:
INSERT INTO MyTable (PriKey, Description) VALUES
('user_input_key','user_input_description')
结果居然还是work,但就是如果user输入了,for example,"mark's",就会报错:
[Microsoft][ODBC Microsoft Access Driver] Syntax error (missing
operator) in query expression "mark's', '".
WHY?Thanks
qb
发帖数: 38
2
use double ' instead of ' mark's -> mark''s

【在 b*******r 的大作中提到】
: 土问题:
: INSERT INTO MyTable (PriKey, Description) VALUES (user_input_key,
: user_input_description)
: 被写成了:
: INSERT INTO MyTable (PriKey, Description) VALUES
: ('user_input_key','user_input_description')
: 结果居然还是work,但就是如果user输入了,for example,"mark's",就会报错:
: [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing
: operator) in query expression "mark's', '".
: WHY?Thanks

1 (共1页)
进入Database版参与讨论
相关主题
Access门外汉问题求教Problem when using SQL " Insert...." to AutoNumber.
correlated subqueryMS T-SQL 问题
About INSERT IGNORE[转载] ASP问题: Operation must use an updateable query
Merge table with one single query?问一个可能看起来很怪的问题
Special character in insert valuesHow to insert a string into table? Thanks
JDBC<======================>Oracle8i请教一个sql server的问题
Set autocommit offhow to include record deleted date into trigger?
请教一个有关SQL concat的问题How to insert CURRENT TIMESTAMP into sql
相关话题的讨论汇总
话题: user话题: sql话题: input话题: mytable