stupid mysql question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mrthumbs
    salad tossing sig guy
    • Apr 2002
    • 11702

    #1

    stupid mysql question

    What happens with my database performance if i define a field as TEXT
    although 90% of the entries will be used for small messages (for which varchar would be most suitable) ?
  • Adultnet
    Confirmed User
    • Sep 2003
    • 8713

    #2
    The performance will be all good but they will decrease with the data since text take more memory. Not some thing that you should feel.


    TrafficCashGold Paying Webmasters Since 1996!

    Awesome Conversions! Fast Weekly Payments! Over 125 Tours!

    Comment

    • mrthumbs
      salad tossing sig guy
      • Apr 2002
      • 11702

      #3
      Originally posted by Adultnet
      The performance will be all good but they will decrease with the data since text take more memory. Not some thing that you should feel.

      Ok.. but lets say.. i store 10.000 records with the word "hello" in a text field
      and i store 10.000 records with the word "hello" in a varchar field on some other database.. no problem there?

      The only issue i can think of is that for example a varcahr(4) reserves actual
      4 bytes of memory while a 4 character text field has a default of 64 bytes or something.. whether you use it or use less.. That would kill performance in the long run.

      Comment

      • grumpy
        Too lazy to set a custom title
        • Jan 2002
        • 9870

        #4
        It doesn take memory space it takes diskspace
        Don't let greediness blur your vision | You gotta let some shit slide
        icq - 441-456-888

        Comment

        Working...