Welcome Guest ( Log In | Register)



 
Reply to this topicStart new topic
> Mysql Field Types, Wont let me go over 255
krap
post Apr 19 2005, 04:47 PM
Post #1


Super Member
*********

Group: Members
Posts: 204
Joined: 6-October 04
From: London, uk
Member No.: 1,444



i got this forum software and i installed it and they text limit is 255 characters (it's a forum for mobile web on mobile phones so thats ok) and i wanted to increase it to 2000 as my members make large posts..
So i go to phpmyadmin, find the field where the post goes in which has the type "varchar(255)" so i edit this and put length/values to 2000 and i get this error:
QUOTE
MySQL said: 
#1074 - Too big column length for column 'text' (max = 255). Use BLOB instead

so i look in the list and find BLOB then try and i get this:
QUOTE
#1170 - BLOB column 'text' used in key specification without a key length

if any1 knows what im doing wrong please post here

thanks in advance
krap
Go to the top of the page
 
+Quote Post
alperuzi
post Apr 19 2005, 05:01 PM
Post #2


delete me
*********

Group: Members
Posts: 518
Joined: 18-September 04
From: delete me
Member No.: 1,185



the maximum length for a varchar in mySQL is 255

I would use a Text field, which has a limit of 65,000 bytes
but I don't know if the forum script you use will support that, you may need to edit the scripts too.
Go to the top of the page
 
+Quote Post
beeseven
post Apr 19 2005, 11:04 PM
Post #3


Privileged Member
*********

Group: Members
Posts: 629
Joined: 26-February 05
Member No.: 3,995



You can use a BLOB or TEXT, but to specify length you'd have to check it in the PHP. Actually, all the length does is specify a cutoff point. If you put "abcdefghijk" into a VARCHAR(5), it'll be stored as "abcde".
Go to the top of the page
 
+Quote Post
Mike
post Apr 22 2005, 12:47 PM
Post #4


Owner of Sub-Zero
********

Group: Members
Posts: 159
Joined: 17-November 04
Member No.: 2,325



Yeah, if you use varchar() it it only goes from 0-255. I would pust something like 'text', and you most likely won't fill that one up.. Or BLOB like the others said; I just don't like using blob. >_>; Or if the text in the field is just going to be numbers, and not any writing or anything, you could use 'bigint' which is from -REALBIGNUMBER to +REALBIGNUMBER >_____>
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Mysql Downtimes...(39)
  2. Mysql Database Setup : Setting Up Mysql Database(6)
  3. Increment A Mysql Column(7)
  4. Import From Excel File Into Mysql Database(11)
  5. Linking To Mysql From Vb(7)
  6. Mysql Database Size(7)
  7. Help Moving Mysql Files To A New Host(2)
  8. Can You Add Images Into A Mysql Database?(21)
  9. Subquery In Mysql(5)
  10. Quick Question(10)
  11. Mysql Won't Update(5)
  12. It Went Well For A While(5)
  13. Mysql Db Is Down Getting Following Error(2)
  14. Need Advice On Setting Up Mysql Database.(4)
  15. The Only Reason I Choose Ms Sql Server Rather Than Mysql(0)
  1. Mysql Database Not Working(3)
  2. Creating A Php Login System Using Mysql(10)
  3. Types Of Networks(2)
  4. Mysql Hacks(6)
  5. Unique Idea. Aromatherapy, Aromadesign And Aromas.(0)
  6. Vb And Mysql(3)
  7. Mysql Server Down(10)
  8. Mccodes With Mysql! [resolved](6)
  9. Website Structure(3)
  10. Php Myadmin(6)
  11. How To Connect Mysql With Jsp ?(4)
  12. Beginning Php And Mysql: From Novice To Professional, Third Edition Review(1)
  13. Os X Mysql Problem(0)


 



- Lo-Fi Version Time is now: 22nd November 2008 - 04:22 PM