SMS처리 도우미
질문답변 일반

datatable serverside 문의 드립니다

작성자 홀스 작성일 2020-12-10 14:46:44 조회수 8301 E-mail chuksan01@gmail.com
이미지 123.12 KB
html 갭쳐.jpg
다운로드
압축 3.47 KBZIP
1607579204639.zip

안녕하세요

지난번 질문드린 datatable 수정 저장 건은 가르쳐 주신대로 해서 잘 저장되고 있습니다.

이번에는 serverside 를 적용하려고 공부중입니다

우선 ajax 로 불러온 자료는 잘 표현됩니다 

1. 그러나 속도가 현저히 느려집니다.  다음 자료 검색시에도 초기와 마찬가지로 느려집니다 

2. 그리고 아래 레코드 숫자 표현도 에러가 발생합니다

3. 검색이 안되는 것 같습니다 (에러발생)

DataTables warning: table id=example - Invalid JSON response. For more information about this error, please see http://datatables.net/tn/1

 

 

4. 그래서 serverside.php 를 보니 다음과 같은 에러가 발생합니다 

Notice: Undefined index: search in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 15

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 15

Notice: Undefined index: order in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Undefined index: start in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 66

Notice: Undefined index: length in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 66

Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, bool given in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 70

Notice: Undefined index: draw in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 83
{ "draw":1, "recordTotal":488787, "recordFiltered":488787, "data": []}Notice: Undefined index: search in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 15

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 15

Notice: Undefined index: order in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Trying to access array offset on value of type null in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 40

Notice: Undefined index: start in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 66

Notice: Undefined index: length in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 66

Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, bool given in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 70

Notice: Undefined index: draw in C:\Bitnami\wampstack\apache2\htdocs\data\2020_save_sever_input.php on line 83
{ "draw":1, "recordTotal":488787, "recordFiltered":488787, "data": []}

 

에러자료를 보면  

$_GET[   ] 으로 가져오는 변수를 잘 정의 못해서 생기는 문제인것 같습니다 

속도도 아마 이것 때문일까요

초보자인지라 여러가지 질문이 많습니다

 

첨부파일에는 html 실행후 화면과 zip파일 올렸습니다 

늘 친절한 답변 감사드립니다 

 


Recent Posts

질문답변 최근 글

질문답변 게시판의 최근 글입니다.

일반 2025-04-28

mcp오류

Comment Thread

댓글

1개
소스놀이터 2020-12-11 00:21
삭제
속도가 현저히 느려지신다고 했는데, 조회 쿼리를 확인해 보세요. select count(*) 쿼리의 where절을 확인해보세요. 데이터 조회 쿼리에는 조건이 3가지인데, select count(*) 시에는 조건이 하나이네요. 그리고, where절에 주로 검색하는 필드에 필요하다면 인덱스 추가하세요.
Write Comment

댓글 작성

X
로그기록