Jump to content

Field shorten in PhpMyAdmin

Go to solution Solved by PravinS,

Recommended Posts

Hi and thanks in advance.


Apologies but I'm a newbie at this.


I've got a field in a MySql (Place_id) table called Pic. Most of the data in that field is in the form #1234 but some are in the format 1234. What I want to do is strip out the # part of the data in every record of that field in the table that contains it. Can anyone help me with the sql please.



Link to comment
Share on other sites

I get an error - this is what I did and the response.



SQL query: b_help.png

FROM `Pic` 
UPDATE Pic SET Place_id = REPLACE( Place_id, '#', '' ) LIMIT 0 ,

MySQL said: b_help.png

#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'UPDATE Pic SET Place_id = REPLACE(Place_id, '#', '')
LIMIT 0, 30' at line 2 

Link to comment
Share on other sites

This thread is more than a year old. Are you sure you have something important to add to it?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.