SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Thread: data types

  1. #1
    SitePoint Addict
    Join Date
    Oct 2010
    Posts
    323
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)

    data types

    hello, i have some variables i have to insert in a table (e.g 00, z1, 54,098 etc) and i am using varchar, but the 00 is inserting as 0.
    please what type am i suppose to store this variable ?

  2. #2
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,215
    Mentioned
    58 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by lostty84 View Post
    please what type am i suppose to store this variable ?
    if you are sure that this column must include values like 'z1' then the only sane choice is VARCHAR
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •