Here's on for you, any help would be greatly appreaciated as it is
sending me mad...
I have three tables tbl_photo, tbl_photo_galle ry and tbl_gallery.
they are linked through primary and and secondary keys as follows:
tbl_photo.photo _id = tbl_photo_galle ry.photo_id
tbl_gallery.gal lery_id = tbl_photo_galle ry.gallery_id
yeat when i try this delete it fails:
delete from tbl_photo where tbl_photo.photo _id =
tbl_gallery_pho to.photo_id and tbl_gallery_pho to.gallery_id = (number)
I tried putting this directly into mysql and got the following error:
Unknown table 'tbl_gallery_ph oto' in where clause
the table definately exists as 'select * from tbl_gallery_pho to' works
fine.
If anyone can help I will buy them a pint one day... please?
sending me mad...
I have three tables tbl_photo, tbl_photo_galle ry and tbl_gallery.
they are linked through primary and and secondary keys as follows:
tbl_photo.photo _id = tbl_photo_galle ry.photo_id
tbl_gallery.gal lery_id = tbl_photo_galle ry.gallery_id
yeat when i try this delete it fails:
delete from tbl_photo where tbl_photo.photo _id =
tbl_gallery_pho to.photo_id and tbl_gallery_pho to.gallery_id = (number)
I tried putting this directly into mysql and got the following error:
Unknown table 'tbl_gallery_ph oto' in where clause
the table definately exists as 'select * from tbl_gallery_pho to' works
fine.
If anyone can help I will buy them a pint one day... please?
Comment