I have used BrowseDownloadToCSV to export browse data to CSV. if the SQL is used in forms SQL then all works fine however when the sql is used in BB, and when export function is called it gives error saying that the base table does not exist.
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'ictfjcom_demo_bis.___nu1665e950dd3bbc___' doesn't exist
. I have created similar function with Jquery only and works fine but limitation only displayed browse data is exported. any idea why temp table id is not recognized in the procedure?.
Temporary tables are not supported by that function. Therefore, in the procedure, you would need to execute procedure BB to create the temporary table, and then run the browse SQL again. This process is more complex than it appears.
kev1n wrote: ↑Tue Jun 04, 2024 8:38 am
Temporary tables are not supported by that function. Therefore, in the procedure, you would need to execute procedure BB to create the temporary table, and then run the browse SQL again. This process is more complex than it appears.
I have used BrowseDownloadToCSV to export browse data to CSV. if the SQL is used in forms SQL then all works fine however when the sql is used in BB, and when export function is called it gives error saying that the base table does not exist.
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'ictfjcom_demo_bis.___nu1665e950dd3bbc___' doesn't exist
. I have created similar function with Jquery only and works fine but limitation only displayed browse data is exported. any idea why temp table id is not recognized in the procedure?.
//Fetch all of the rows from our table
$rows = $statement->fetchAll(PDO::FETCH_ASSOC);
// added: drop the table if it exists
if ($tt != "") {
$statement = $pdo->prepare("DROP TABLE $tt");
$statement->execute();
}
kev1n wrote: ↑Sat Jun 08, 2024 7:47 am
Here's the updated download code, leveraging the latest nuBuilder functions and incorporating nuRunPHPWithParams() from the updated nuajax.js
Thanks kevin, apologies for late reply, have tested the code and works as expected.