jbyte007 Posted April 4, 2003 Share Posted April 4, 2003 I am getting this error when trying to get pass an order. I have read the other posts and dont know what to do.. My PHP and MYSQL skills are a 0. I need to get this working today. I am willing to pay a person to dive in an fix it. Please, Please help.. Error::: 1054 - Unknown column 'customers_company' in 'field list' Again please help, we are neededing to get this launched for a trade show.. THanks, Jason Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 You need to either create a column in your customers table of the database, or you need to delete the reference to in in the query. I am not willing to do it for you. I am willing to talk you through it. You need phpmyadmin for the first method. Or, you need to edit the script to remove the reference. To do this, first serch for the INSERT statement in order_details.php. ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 Which process would be best.. Where is the order_details.php file located, and would would I do after I find the INSERT? THANK YOU SO MUCH FOR YOUR HELP!!!!!!!!!!!!! Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 Ok I got my self logged into PHPMyAdmin.. Now what would I do? THanks again.. Jason Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 yeah, the phpmyadmin is probably the easist way, but it is also the lest efficient, since you afe trying to populate a table you don't have. Anyway, in order to try this, you need to know what order to insert the column in. Just after the error message you posted, should be displayed the full SQL query. Look for that and post it here. ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 OK, now go into phpmyadmin, and click on the 'customer' table to the left. Then scroll down and look for 'add new field' It will give you a drop down for where you wnat to add it. Lok in your query and add it in the right order. Then hit go. The next screen, you put the name ofthe field first, which is the one your are missing. copy it form the error you get and paste it there. Make sure there isn't a tailing space. Leave the datatype as varchar, and insert 25 into the length, just in case you ever decide to use this field. Change the 'not null' to 'null' Leave the rest the same. Hit Save and BAM, "Bob's your Uncle". ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 Ok I am following you up to "look into my query". The pull down list to tell it where to insert the new field has the following: custoemr_id customer_gender customer_firstname customer_lastname customer_dob customer_email_address ect... From what i can understand of the quary, it says it hsould be inserted after the customers_name, but that is not in the pull down list.. See my errror: 1054 - Unknown column 'customers_company' in 'field list' insert into orders (customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, Thanks,,, Jason Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 Also are we doing this to the ORDERS or the Customers tabel. In looking at the orders tabel it looks like that has the customer_name colum. Am I correct on this one? Thanks Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 Opps, I'm sorry, you are correct. Switch to the 'Orders' table. Make sure that there isn't already a 'customers_company' in the list of columns. If there is, click the chck mark next ot it, and scroll down and hit 'drop' Then scroll down to 'add new field" select after customers name and hit Go. On the next page, make the name 'customers_company' , length 32, and null "null". That should do it. ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 Progress, but still errors.. Now I am getting the same error, but different field.. So I have repeated the steps, then another field, again repeated the steps, now I see that if this is the correct process I will ahve to do this for all the 'billing" fields. Is this correct? Should the value still be NULL on these? See the output in prvevious post.. Thanks again for all your help.. Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 well, any fields it cant find are fields that you are trying to insert data into. Obviously, you installed a contribuion or something that added athings to the query that you don't have. Just don't delete any fields that might contain data in them. But if you are getting an error, and you don't see it in the table, you can safely add it to the table. ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
jbyte007 Posted April 4, 2003 Author Share Posted April 4, 2003 IT WORKS!!! Ok after many many field inserts in two tables it worked.. Thank you so much for helping me out. I cant say thanks enough.. Also just as an FYI I did not install any MODS, so dont know why the fields were not their.. Last question, in setting all those missing fields to NULL what does that effect or not effect? Thanks again, Jason Link to comment Share on other sites More sharing options...
wizardsandwars Posted April 4, 2003 Share Posted April 4, 2003 It allows nulls to be entered into the fields. Any you're welcome. :lol: ------------------------------------------------------------------------------------------------------------------------- NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit. If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.