Solved

php mysql update database what wrong with it

Posted on 2006-11-07
4
198 Views
Last Modified: 2011-10-03
update
sellhead.NewCCode  = customer.id
where  AOL.sellhead inner join AOL.customer on sellhead.CCode = customer.Code
0
Comment
Question by:teera
  • 3
4 Comments
 
LVL 35

Accepted Solution

by:
Raynard7 earned 350 total points
ID: 17895796
try

update sellhead, customer set sellhead.NewCCode  = customer.id where  sellhead.CCode = customer.Code
0
 
LVL 35

Expert Comment

by:Raynard7
ID: 17895798
0
 

Author Comment

by:teera
ID: 17895819
update  sellhead
set sellhead.NewCCode  = customer.id
where  AOL.sellhead inner join AOL.customer on sellhead.CCode = customer.Code
0
 
LVL 35

Expert Comment

by:Raynard7
ID: 17895837
no,

you need to mention both tables at the beginning - then join them later

just as I gave - and as the examples in what I posted above.

so

update sellhead, customer set sellhead.NewCCode = customer.id where sellhead.CCode = customer.Code
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
change password links 7 72
Is this error or Notice in php error log? 6 32
Form Processing in PHP 11 30
echo time from sql to input type="time" 9 17
Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
This article discusses how to create an extensible mechanism for linked drop downs.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now