Muhammad Muqorrobin Muhammad Muqorrobin - 1 month ago 10
JSON Question

cant load more than 100 words in json android from sql

i have issues error when i am trying to load more than 100 words in json..

this is my code php

$result = array();
$query = "SELECT id_lw,judul_lw,left(deskripsi_lw,100)deskripsi_lw,
latitude_lw,longitude_lw,nama_p,nama_k,
status_lw,gambar_lw
from lokasi_wisata
JOIN kabupaten as kabupaten ON kabupaten.IDKabupaten = lokasi_wisata.IDKabupaten
JOIN provinsi as provinsi ON provinsi.IDProvinsi = lokasi_wisata.IDProvinsi
WHERE nama_k LIKE '%$namekab%'
GROUP BY judul_lw " ;
$res = mysql_query($query);

while ($fetch = mysql_fetch_assoc($res)) {
$result[] = $fetch;
}
// print_r($result);
echo mysql_error();
echo json_encode(array('res'=>$result)); :


when i changed left(deskripsi_lw,100)deskripsi_lw into 200 or more .. the result is nothing ..

the type data of deskripsi_lw is TEXT on my sql

Answer

It still works if you use sout in java

Comments