DrAwesomePhD Posted February 23, 2006 Share Posted February 23, 2006 Hi, i'm sure this is a really stupid question, but could anyone please tell me the command to insert data into a certain part of the table? It seems my command that i've used before is being tempermental :-/I'm trying to change the value of my account (charname=Jeht member_id = 1) in the access field to 15 from null. I've tried this:INSERT INTO members (access) VALUES ('15') WHERE charname = 'Jeht';and its not happy with the "WHERE" part of it .... anyone plz help? and sorry for my noobness :-/ Quote Link to comment https://forums.phpfreaks.com/topic/3554-inserting-data-into-a-specific-part-of-a-row/ Share on other sites More sharing options...
fenway Posted February 23, 2006 Share Posted February 23, 2006 Think update, not insert -- the row is already there!Try the following:[code]UPDATE members SET access = '15' WHERE charname = 'Jeht';[/code]Make sense? Quote Link to comment https://forums.phpfreaks.com/topic/3554-inserting-data-into-a-specific-part-of-a-row/#findComment-12267 Share on other sites More sharing options...
DrAwesomePhD Posted February 23, 2006 Author Share Posted February 23, 2006 Ah thanks so much. So INSERT must be for new rows only.... thanks ^_^ good to know. Quote Link to comment https://forums.phpfreaks.com/topic/3554-inserting-data-into-a-specific-part-of-a-row/#findComment-12289 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.