Logstash Statment Dynamic Parameter

Hi all. I have tried to connect logstash with mysql and now I am getting error associated with dynamic parameter of statment.

jdbc_connection_string => "jdbc:mysql://localhost:3306/mydb"
		jdbc_user => "vuser"
		jdbc_password => "_aerhi64N_"
		jdbc_driver_library => "C:\servers\Elasticsearch\logstash-2.2.2\drivers\mysql-connector-java-5.1.5.jar"
		jdbc_driver_class => "com.mysql.jdbc.Driver"
		statement => "SELECT * FROM :table_name"

I want to pass this table_name parameter via php.

You're starting Logstash from PHP, or what do you mean? If yes, your best bet is probably to generate a file with the SQL statement and pass that file to Logstash via the statement_filepath option.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.