Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

What's a dialect?

A dialect defines how Pentaho Metadata should generate SQL for a given database type.

Metadata's Dialect Plugin System

Introduced in release 3.7 Pentaho Metadata supports additional dialects through a self-registering plugin system: Java's ServiceLoader API. A dialect is a concrete implementation of SQLDialectInterface and, in order for Pentaho Metadata to recognize it, you must declare it as a Service Provider and package it in a jar. That being said, a Pentaho Metadata Dialect Plugin is a jar file that consists of a dialect implementation and some configuration.

Implementing SQLDialectInterface

Declaring your Dialect as a Service Provider

The Java Service Loader API requires you list all Service Provider implementations in a file named after the interface of the service they provide in the META-INF/services directory of the jar file.

  • META-INF/services/org.pentaho.pms.mql.dialect.SQLDialectInterface

To define a Pentaho Metadata Dialect you must implement org.pentaho.pms.mql.SQLDialectInterface and define the implementation as a Service Provider[1].

Using your plugin

[1]: http://download.oracle.com/javase/6/docs/technotes/guides/jar/jar.html#Service%20Provider|http://download.oracle.com/javase/6/docs/technotes/guides/jar/jar.html#Service%20Provider]

  • No labels