how to use sql in php

Discussion in 'MySQL' started by anchitjindal07, Aug 28, 2009.

  1. anchitjindal07

    anchitjindal07 New Member

    Joined:
    Jul 13, 2009
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    1
    Sql is used for creating databases which consists of tables. But what ot do if we want to store some data which is in the form of paragraph of text....... For eg if we want to store contents of 'about us' page of a website in database what we will do
     
  2. nimesh

    nimesh New Member

    Joined:
    Apr 13, 2009
    Messages:
    769
    Likes Received:
    20
    Trophy Points:
    0
    Occupation:
    Oracle Apps Admin
    Location:
    Mumbai
    Home Page:
    http://techiethakkar.blogspot.com
    Depending on the text size you can use any of the below

    TINYBLOB, TINYTEXT - L + 1 bytes, where L < 28
    BLOB, TEXT - L + 2 bytes, where L < 216
    MEDIUMBLOB, MEDIUMTEXT - L + 3 bytes, where L < 224
    LONGBLOB, LONGTEXT - L + 4 bytes, where L < 232

    For more on Datatypes in MySQL, refer this
    http://dev.mysql.com/doc/refman/5.0/en/storage-requirements.html
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice