|
||||||
| PHP Forum Use this forum to discuss all aspects of PHP Development. PHP is a server-side, cross-platform, HTML embedded scripting language that lets you create dynamic web pages. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
Hello everyone!
I am new to mysql and php. I do have some knowledge of C++, Java, and ASP. This is the deal: I bought the oscommerce for professionals to help with a website I need to create. I downloaded and installed the MySql version 5.01. Installations was successful. command line prompt per book directions. mysql> use mysql database changed mysql> insert into users values( --> 'localhost', -->'username', -->Password('password'), -->'Y','Y','Y','Y','Y','Y','Y', -->'N','N','N','N','N','N','N','N','N','N','N', -->'N','N','N','N','N','N','N','N','N','N'); RETURNS THIS: ERROR 1136 (21S01): Column count doesn't match value count at row 1 mysql> I have done some exploring and found out that this means there are more values listed than there are columns in the table. My question is how do I find out how many columns there are in the table from the command line? This is suppose to an easy exercise just to make sure it works. haha I have been at this for almost 16 hours. I have not even d/l php yet. Any help would be greatly appreciated! Thanks in advance, dink |
| Sponsored Links |
|
|
|
|||
|
Thanks orjan!
I could not have done this with out your help. The textbook leaves out a lot of vital information for a newbie. I finally got it to work by inserting field names and then the values for the fields that did not have default values. INSERT INTO user (Host,User,Password,ssl_cipher,x509_issuer,x509_su bject) VALUES('localhost','myuser','mypassword','null','n ull','null'); There is no way I could have found this information on my own. It only took me 30 minutes to figure out the code you posted needed a semicolon to work. haha Again thanks and I really appreciate your help. Who knows maybe some day I can help some one. ![]() dink |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Tutorial: Storing Images in MySQL with PHP | Jordan | PHP Tutorials | 13 | 09-23-2008 07:11 PM |
| Column count doesn't match value count at row 1 | shiyam198 | PHP Forum | 7 | 09-07-2008 03:13 PM |
| Java:Tutorial - Tic-Tac-Toe | John | Java Tutorials | 25 | 02-27-2008 07:41 PM |
| MySQL Error: #1052 - Column 'id' in field list is ambiguous | Crane | Database & Database Programming | 2 | 09-30-2007 10:16 AM |
| MySQL Resources | dirkfirst | Database & Database Programming | 1 | 05-25-2006 03:31 AM |
| WingedPanther | ........ | 2753.6 |
| Xav | ........ | 2704 |
| Brandon W | ........ | 1702.32 |
| John | ........ | 1207.73 |
| marwex89 | ........ | 1175.24 |
| morefood2001 | ........ | 966.05 |
| dcs | ........ | 655.75 |
| Steve.L | ........ | 475.59 |
| orjan | ........ | 418.58 |
| Aereshaa | ........ | 383.54 |
Goal: 100,000 Posts
Complete: 97%