INSERT with SELECT

Yes, absolutely, but check your syntax. INSERT INTO courses (name, location, gid) SELECT name, location, 1 FROM courses WHERE cid = 2 You can put a constant of the same type as gid in its place, not just 1, of course. And, I just made up the cid value.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)