Click here to Skip to main content
15,881,690 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi friends
how to insert hobby in coma separate in one field in database like i have three hobyy playing cooking and reading and i have insert like hobby,cooking,reading so how to it possible
thanks
Posted
Updated 10-Jun-13 0:49am
v2

I doesn't look a good idea (it goes in the opposite direction of database normalization principles).
In any case, it is not difficult: just a call to the String.Replace[^] method could do the trick.
 
Share this answer
 
Comments
Abhinav S 10-Jun-13 6:54am    
My answer exactly. No normalization.
_Amy 10-Jun-13 7:09am    
+5!
CPallini 10-Jun-13 7:52am    
Thank you.
Nandakishore G N 10-Jun-13 7:57am    
exact answer. My 5.
Comma limited items should not be inserted into a table.
Split these items up into values that you would store in another table and join these two tables whenever you want results.
 
Share this answer
 
Comments
_Amy 10-Jun-13 7:09am    
Exactly. +5!
Abhinav S 10-Jun-13 7:12am    
Thank you.
CPallini 10-Jun-13 7:52am    
5. :-)
Abhinav S 10-Jun-13 8:40am    
Thank you CPallini.

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