Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error adding jdbc-dir #307

Open
MEDLCL opened this issue Jan 21, 2022 · 1 comment
Open

Error adding jdbc-dir #307

MEDLCL opened this issue Jan 21, 2022 · 1 comment

Comments

@MEDLCL
Copy link

MEDLCL commented Jan 21, 2022

i have one error
Error adding jdbc-dir

my code
require DIR . '/../vendor/autoload.php';

use PHPJasper\PHPJasper;
$idcalculo = 10;

$pass = "Noviembre2023";
$input = DIR . '/../vendor/lavela/phpjasper/examples/rptCalculo.jasper';
$output = DIR . '/../vendor/lavela/phpjasper/examples';
$jdbc_dir = DIR . '/../vendor/lavela/phpjasper/bin/jaspertarter/jdbc';
$options = [
'format' => ['pdf', 'rtf'],
'locale' => 'en',
"params" => ["idcalculo" => $idcalculo],
'db_connection' => [
'driver' => 'generic',
'host' => 'localhost',
'port' => '3307',
'database' => 'almadisa',
'username' => 'root',
'password' => $pass,
'jdbc_driver' => 'com.mysql.cj.jdbc.Driver',
//'jdbc_driver' => 'mariadb-java-client-3.0.0-alpha',
'jdbc_url' => '"jdbc:mysql://localhost:3307;databaseName=almadisa"',
'jdbc_dir' => $jdbc_dir
]
];
//com.mysql.jdbc.Driver
$jasper = new PHPJasper;
$x=exec($jasper->process(
$input,
$output,
$options
)->output());
echo $x;
help please

@alissonalberini
Copy link

Just remove the parameter, by default within the package its respective path has already been defined.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants