에러 : 1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near > 그누4 질문답변

그누4 질문답변

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기
기존 게시물은 열람만 가능합니다.

에러 : 1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 정보

에러 : 1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near

본문

안녕하세여.
테이블을 하나 만들었어여...그리고, 거기에 자료를 입력하는데여.

아무리 해도 에러가 나네요...

insert set fc_1 = '10.65', fc_2 = '12.72', fc_3 = '11.58', fc_use = 'System', fc_date1 = '20100313105121'

1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'set fc_1 = '10.65', fc_2 = '12.72', ' at line 2


왜 그런지 좀 알려주세여....

구문은 다음과 같습니다.

sql_query("insert $g4[test_table]
          set fc_1 = '{$fc_1[$i]}',
                fc_2 = '{$fc_2[$i]}',
                fc_3 = '{$fc_3[$i]}',
fc_use      = '{$fc_name}',
fc_date1    = '{$fc_date[$i]}'");
sql_query($sql);
$fc_id = mysql_insert_id();


참고로, 테이블  `fc_1` decimal(10,2) NOT NULL default '0.00',  형식이거든여...1, 2, 3 모두 같아여..
  • 복사

댓글 전체

sql_query("insert  into  $g4[test_table]  <-- into  문을 추가해 보세용 ;;
          set fc_1 = '{$fc_1[$i]}',
                fc_2 = '{$fc_2[$i]}',
                fc_3 = '{$fc_3[$i]}',
fc_use      = '{$fc_name}',
fc_date1    = '{$fc_date[$i]}'");
sql_query($sql);
$fc_id = mysql_insert_id();
$g4[test_table] <= 이 값이 있는지 보세요.

에러에 테이블 값이 없습니다.

 insert XXXX set fc_1 = '10.65', fc_2 = '12.72', fc_3 = '11.58', fc_use = 'System', fc_date1 = '20100313105121'

XXXX 부분에 테이블 ($g4[test_table]) 값이 나타나야 하는데 없습니다.
그리고 방황하는중년님이 말씀하신 into 도 추가하심이....
그러고 보니, 테이블 값이 안나오네여....흠...
제가 사용한 구문이 틀린건가여..??  테이블 값이 안나와서 그러는 것일수도 있겠는데여..??

그누보드 처음 생성할때 기본으로 생성되는 테이블 말고..
추가로 만드는것 같은경우, 테이블을 만들고, 또 다른 뭔가를 해줘야 하나여..??
답변 감사합니다.

config 에 값을 안넣었던게 문제였던거 같습니다.....값을 넣고 나니, 정상적으로 기록은되는데,

1065 : Query was empty  라는 에러가 나오네여....ㅠㅠ

휴....이제 정상기록은 되는걸 확인했으니....에러를 잡아야겠군여....에궁
© SIRSOFT
현재 페이지 제일 처음으로