Click here to Skip to main content
15,891,204 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
SELECT FROM Table where city:pp"
Posted
Updated 17-May-14 22:38pm
v2
Comments
PIEBALDconsult 18-May-14 0:16am    
What seems to be the trouble?
OriginalGriff 18-May-14 0:26am    
This is not a good question - we cannot work out from that little what you are trying to do.
Remember that we can't see your screen, access your HDD, or read your mind.
Perhaps telling us what the error message was would help?
Use the "Improve question" widget to edit your question and provide better information.
Meysam Toluie 18-May-14 0:31am    
Hi Sir.
I have added a solution but I can not see that myself. Can you see any solution here?
Its reputation also added to my reputation.

Try enclose User with [ ], i.e. [User]
However, you should avoid using sql keyword like 'user', suggest change it 'users'.
read more: Reserved Keywords (Transact-SQL)[^]
 
Share this answer
 
v3
SQL
IF (SELECT Count(*) FROM User WHERE NricNo = @userNric) = 0
  Begin
     INSERT INTO User (NricNo, Name, Username, Password, ConfirmPassword, Role , Image)
     VALUES (@userNric, @nameUser , @userName, @userPassword, @userConfirmPassword, @userRole, @userImage)
  End
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900