$write_table 말고 테이블이름 쓰는방법문의 채택완료
거너비ok
8년 전
조회 4,801
</p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><?php </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index10"></span>$sql3 = " select * FROM $write_table left join g5_scrap on $write_table.wr_id=g5_scrap.wr_id where g5_scrap.mb_id='{$member['mb_id']}' && g5_scrap.bo_table='{$board['bo_table']}'";</span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="tall_linebreak" style="line-height: 16px;">
</span></span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index11"></span>//현재 게시판DB와 스크랩DB 비교해서 로그인 아이디로 스크랩된 게시물 찾기 </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index12"></span>$result3 = sql_query($sql3); </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index13"></span>for ($k=0; $row3=sql_fetch_array($result3); $k++) { </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index14"></span> $row3['opener_href_wr_id'] = './board.php?bo_table='.$row3['bo_table'].'&wr_id='.$row3['wr_id']; </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"><span class="masha_index masha_index15"></span> $Sdate = substr($row3['wr_datetime'],0,10); </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"> ?> </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;"> </span></p><p style="word-break: break-all; color: rgb(34, 34, 34); font-family: "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", 돋움, dotum, sans-serif; font-size: 21px; background-color: rgb(255, 255, 255);"><span style="font-size: 11pt;">
이 코드가 해당 테이블과 스크랩 테이블의 조인으로 알고 있는데요
제가 텅빈 테이블 (ev2) 하나를 만들어서
이 코드를 넣으면 당연 아무것도 글자체가 안나오고요
불러오고 싶은 테이블은 ev1 이고요 ( ev1테이블이 아닌 ev2 테이블에서 불러오는거임)
ev1 테이블과 스크랩 테이블의 조인코드를
ev2 테이블에다가 집어넣는거라서
$write_table 여기가 ev1이 되야되는데요
어떻게 넣어야 될까요?
댓글을 작성하려면 로그인이 필요합니다.
답변 2개
채택된 답변
+20 포인트
답변에 대한 댓글 1개
�
거너비ok
8년 전
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인
$sql3 = " select * FROM g5_write_ev1 left join g5_board_good on g5_write_ev1.wr_id=g5_board_good.wr_id where g5_board_good.mb_id ='{$member['mb_id']}' && g5_board_good.bo_table='{$board['bo_table']}'";
이렇게 쪼인하는게 맞나요?
스크랩 말규 추천테이블로 하려고 해서요..