NamePros
Welcome, Guest! Ready to make a name for yourself in the domain business? We welcome both the hobbyist and professional domainer to join the discussion as part of the NamePros community.

Click here to create your profile to start earning reputation for posting, and trader ratings for buying & selling in our free e-marketplace. Build your trader rating with each successful sale. Our system has tracked over 100,000 sales and counting!
FAQ & TOS Register Search Today's Posts Mark Forums Read

Go Back   NamePros.com > Website Development Discussion Forums > Programming
Reload this Page [resolved] database help needed asap!!!

Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics.

Advanced Search


Closed Thread
 
LinkBack Thread Tools
Old 11-14-2007, 07:59 PM THREAD STARTER               #1 (permalink)
NamePros Member
Join Date: Dec 2005
Posts: 79
tez30 is an unknown quantity at this point
 



database help needed asap!!!


i'm catch hell with this tables(my first time working with them)
when i test my registration for my site i get's this error

Error in checking :Table 'playstat_ps2t.users' doesn't exist


so i opened cpanel and opened phpmyadmin to create my tables then i got this error

Error
SQL query:

CREATE TABLE `members` (

`username` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL AUTO_INCREMENT ,
`password` VARCHAR( 16 ) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`first_name` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`last_name` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`address` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`city` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`state` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`interested_game` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`email_address` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL ,
`phone_number` INT( 11 ) NOT NULL ,
????: NamePros.com http://www.namepros.com/programming/395891-resolved-database-help-needed-asap.html
`age` INT( 2 ) NOT NULL
) ENGINE = MYISAM CHARACTER SET utf8 COLLATE utf8_unicode_ci COMMENT = 'registration for ps2-tournament'

MySQL said:

#1063 - Incorrect column specifier for column 'username'

can anybody please help me out?
thanks in advance.
__________________
http://www.gamershowdown.net
tez30 is offline  
Old 11-14-2007, 08:14 PM   #2 (permalink)
NamePros Regular
 
baxter's Avatar
Join Date: Apr 2006
Posts: 363
baxter is just really nicebaxter is just really nicebaxter is just really nicebaxter is just really nice
 


Ethan Allen Fund Save The Children
you have username field set to text and you can't auto increment a text field. I believe thats what the error is telling you.
__________________
Canadian Domain Registrar Ready.ca
baxter is offline  
Old 11-15-2007, 12:05 AM   #3 (permalink)
i love automation
 
xrvel's Avatar
Join Date: Nov 2007
Location: xrvel.com
Posts: 1,620
xrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant futurexrvel has a brilliant future
 




Table 'playstat_ps2t.users' doesn't exist

Have you created a table which is named users , in database playstat_ps2t ?
xrvel is offline  
Old 11-15-2007, 07:56 AM THREAD STARTER               #4 (permalink)
NamePros Member
Join Date: Dec 2005
Posts: 79
tez30 is an unknown quantity at this point
 



know i'm getting this error:

Error in registering user : .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 'sab2829@yahoo.com','334-749-3616',0,'%2007-%11-%15 %09-%45-%02','s.c.a#',0,'28ae' at line 1
__________________
http://www.gamershowdown.net
tez30 is offline  
Old 11-15-2007, 09:03 AM   #5 (permalink)
NamePros Expert
 
Peter's Avatar
Join Date: Nov 2003
Location: Scotland
Posts: 5,069
Peter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond repute
 


Child Abuse Save The Children Save The Children Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009
can you show us the full SQL you are trying to execute.
__________________
Manage your portfolio using my new Domain Portfolio Management script.
Securing Your Domain Name From Theft
Peter is offline  
Old 11-15-2007, 09:23 AM THREAD STARTER               #6 (permalink)
NamePros Member
Join Date: Dec 2005
Posts: 79
tez30 is an unknown quantity at this point
 



this is the sql i'm triing to execute:

Field Type - Collation ---- Attributes ---- Null --- Default --- Extra Action
username - text ---- utf8_unicode_ci -- No
password - varchar(16) - utf8_unicode_ci -- No
first_name - text -------- utf8_unicode_ci -- No
????: NamePros.com http://www.namepros.com/showthread.php?t=395891
last_name - text -------- utf8_unicode_ci -- No
address --- text -------- utf8_unicode_ci -- No
city ------- text -------- utf8_unicode_ci -- No
state ----- text --------- utf8_unicode_ci -- No
interested_game - text -- utf8_unicode_ci -- No
email_address - text ---- utf8_unicode_ci -- No
phone_number - int(11) -- -- No
age ------ int(2) -------- -- No

can anybody tell me what i'm doing wrong?
__________________
http://www.gamershowdown.net
tez30 is offline  
Old 11-15-2007, 10:39 AM   #7 (permalink)
NamePros Expert
 
Peter's Avatar
Join Date: Nov 2003
Location: Scotland
Posts: 5,069
Peter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond repute
 


Child Abuse Save The Children Save The Children Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009
that isnt the sql you are trying to execute that looks more like a copy of the table structure.
__________________
Manage your portfolio using my new Domain Portfolio Management script.
Securing Your Domain Name From Theft
Peter is offline  
Old 11-15-2007, 11:33 AM   #8 (permalink)
NamePros Expert
 
Peter's Avatar
Join Date: Nov 2003
Location: Scotland
Posts: 5,069
Peter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond repute
 


Child Abuse Save The Children Save The Children Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009
okay had a quick look and it looks to me like you are trying to enclose $game in single quotes for the SQL but you did not close them

Change

PHP Code:
$qry mysql_query("insert into users(affid,username,password,fname,lname,address, city,state,game,paypalemailaddress,phone,credits,d ateapplied,notify,active,confirmcode) ".
" values(".$affid.",'".$uname."','".$pwd."','".$fname."','".$lname."','".$address."','".$city."','".$state."','".$game.
",'".$email."','".$ph."',".$credits.",'".date('%Y-%m-%d %H-%i-%s')."','".$game."#',0,'".$code."')") or die("Error in registering user : $username .".mysql_error()); 
Too

PHP Code:
$qry mysql_query("insert into users(affid,username,password,fname,lname,address, city,state,game,paypalemailaddress,phone,credits,d ateapplied,notify,active,confirmcode) ".
" values(".$affid.",'".$uname."','".$pwd."','".$fname."','".$lname."','".$address."','".$city."','".$state."','".$game.
"','".$email."','".$ph."',".$credits.",'".date('%Y-%m-%d %H-%i-%s')."','".$game."#',0,'".$code."')") or die("Error in registering user : $username .".mysql_error()); 
????: NamePros.com http://www.namepros.com/showthread.php?t=395891
????: NamePros.com http://www.namepros.com/showthread.php?t=395891
__________________
Manage your portfolio using my new Domain Portfolio Management script.
Securing Your Domain Name From Theft
Peter is offline  
Old 11-15-2007, 12:21 PM THREAD STARTER               #9 (permalink)
NamePros Member
Join Date: Dec 2005
Posts: 79
tez30 is an unknown quantity at this point
 



now i'm gettin this error:

Error in registering user : .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 'ateapplied,notify,active,confirmcode) values(0,'test','12345','joe','horn'' at line 1

do i have to have a field for all of these?
__________________
http://www.gamershowdown.net
Last edited by tez30; 11-19-2007 at 08:29 AM.
tez30 is offline  
Old 11-15-2007, 12:54 PM   #10 (permalink)
NamePros Expert
 
Peter's Avatar
Join Date: Nov 2003
Location: Scotland
Posts: 5,069
Peter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond repute
 


Child Abuse Save The Children Save The Children Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009
Yes there has to be a filed which correspond to each of those within the users table
__________________
Manage your portfolio using my new Domain Portfolio Management script.
Securing Your Domain Name From Theft
Peter is offline  
Old 11-16-2007, 04:50 AM THREAD STARTER               #11 (permalink)
NamePros Member
Join Date: Dec 2005
Posts: 79
tez30 is an unknown quantity at this point
 



thanks alot peter@flexiwebhost, i fixed it
__________________
http://www.gamershowdown.net
tez30 is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Liquid Web Smart Servers  
All times are GMT -7. The time now is 09:20 AM.

Managed Web Hosting by Liquid Web
Domain name forum recommended by Domaining.com Powered by: vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0 Ad Management plugin by RedTyger