blob: 284f845896f7402207e00203115e0c57b75b8670 [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.4) on Fri Sep 20 12:10:30 CEST 2019 -->
<title>SQLTranslator (Apache SIS 1.0 API)</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="dc.created" content="2019-09-20">
<meta name="keywords" content="org.apache.sis.referencing.factory.sql.SQLTranslator class">
<meta name="keywords" content="getCatalog()">
<meta name="keywords" content="getSchema()">
<meta name="keywords" content="apply()">
<link rel="stylesheet" type="text/css" href="../../../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../../sis.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../../jquery/jquery-ui.css" title="Style">
<script type="text/javascript" src="../../../../../../script.js"></script>
<script type="text/javascript" src="../../../../../../jquery/jszip/dist/jszip.min.js"></script>
<script type="text/javascript" src="../../../../../../jquery/jszip-utils/dist/jszip-utils.min.js"></script>
<!--[if IE]>
<script type="text/javascript" src="../../../../../../jquery/jszip-utils/dist/jszip-utils-ie.min.js"></script>
<![endif]-->
<script type="text/javascript" src="../../../../../../jquery/jquery-3.3.1.js"></script>
<script type="text/javascript" src="../../../../../../jquery/jquery-migrate-3.0.1.js"></script>
<script type="text/javascript" src="../../../../../../jquery/jquery-ui.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="SQLTranslator (Apache SIS 1.0 API)";
}
}
catch(err) {
}
//-->
var data = {"i0":10,"i1":10,"i2":10};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
var pathtoroot = "../../../../../../";
var useModuleDirectories = false;
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<header role="banner">
<nav role="navigation">
<div class="fixedNav">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a id="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/SQLTranslator.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../../allclasses.html">All&nbsp;Classes</a></li>
</ul>
<ul class="navListSearch">
<li><label for="search">SEARCH:</label>
<input type="text" id="search" value="search" disabled="disabled">
<input type="reset" id="reset" value="reset" disabled="disabled">
</li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a id="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
</div>
<div class="navPadding">&nbsp;</div>
<script type="text/javascript"><!--
$('.navPadding').css('padding-top', $('.fixedNav').css("height"));
//-->
</script>
</nav>
</header>
<!-- ======== START OF CLASS DATA ======== -->
<main role="main">
<div class="header">
<div class="subTitle"><span class="packageLabelInType">Package</span>&nbsp;<a href="package-summary.html">org.apache.sis.referencing.factory.sql</a></div>
<h2 title="Class SQLTranslator" class="title">Class SQLTranslator</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></li>
<li>
<ul class="inheritance">
<li>SQLTranslator</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true" title="class or interface in java.util.function" class="externalLink">Function</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></dd>
</dl>
<hr>
<pre>public class <span class="typeNameLabel">SQLTranslator</span>
extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>
implements <a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true" title="class or interface in java.util.function" class="externalLink">Function</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</pre>
<div class="block">Converts the SQL statements from MS-Access dialect to standard SQL. The <a href="#apply(java.lang.String)"><code>apply(String)</code></a> method
is invoked when a new <a href="https://docs.oracle.com/javase/8/docs/api/java/sql/PreparedStatement.html?is-external=true" title="class or interface in java.sql" class="externalLink"><code>Prepared­Statement</code></a> is about to be created from a SQL string.
Since the <a href="http://www.epsg.org">EPSG dataset</a> is available primarily in MS-Access format,
the original SQL statements are formatted using a dialect specific to that particular database software.
If the actual EPSG dataset to query is hosted on another database product, then the SQL query needs to be
adapted to the target database dialect before to be executed.
<div class="note"><b>Example</b>
SQL statements for an EPSG dataset hosted on the <cite>PostgreSQL</cite> database need to have their brackets
(<code>'['</code> and <code>']'</code>) replaced by the quote character (<code>'"'</code>) before to be sent to the database
driver. Furthermore table names may be different. So the following MS-Access query:
<ul>
<li><code>SELECT * FROM [Coordinate Reference System]</code></li>
</ul>
needs to be converted to one of the following possibilities for a PostgreSQL database
(the reason for those multiple choices will be discussed later):
<ul>
<li><code>SELECT * FROM "Coordinate Reference System"</code></li>
<li><code>SELECT * FROM epsg_coordinatereferencesystem</code> (in the default schema)</li>
<li><code>SELECT * FROM epsg​.coordinatereferencesystem</code> (in the <code>"epsg"</code> schema)</li>
<li><code>SELECT * FROM epsg."Coordinate Reference System"</code></li>
</ul></div>
In addition to the file in MS-Access format, EPSG also provides the dataset as SQL files for PostgreSQL,
MySQL and Oracle databases. Those SQL files are used as both <cite>Data Description Language</cite> (DDL)
and <cite>Data Manipulation Language</cite> (DML).
But the table names and some column names in those scripts differ from the ones used in the MS-Access database.
The following table summarizes the name changes:
<table class="sis">
<caption>Table and column names</caption>
<tr><th>Element</th><th>Name in MS-Access database</th> <th>Name in SQL scripts</th></tr>
<tr><td>Table</td> <td><code>Alias</code></td> <td><code>epsg_alias</code></td></tr>
<tr><td>Table</td> <td><code>Area</code></td> <td><code>epsg_area</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate Axis</code></td> <td><code>epsg_coordinateaxis</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate Axis Name</code></td> <td><code>epsg_coordinateaxisname</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation</code></td> <td><code>epsg_coordoperation</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation Method</code></td> <td><code>epsg_coordoperationmethod</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation Parameter</code></td> <td><code>epsg_coordoperationparam</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation Parameter Usage</code></td> <td><code>epsg_coordoperationparamusage</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation Parameter Value</code></td> <td><code>epsg_coordoperationparamvalue</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate_Operation Path</code></td> <td><code>epsg_coordoperationpath</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate Reference System</code></td> <td><code>epsg_coordinatereferencesystem</code></td></tr>
<tr><td>Table</td> <td><code>Coordinate System</code></td> <td><code>epsg_coordinatesystem</code></td></tr>
<tr><td>Table</td> <td><code>Datum</code></td> <td><code>epsg_datum</code></td></tr>
<tr><td>Table</td> <td><code>Ellipsoid</code></td> <td><code>epsg_ellipsoid</code></td></tr>
<tr><td>Table</td> <td><code>Naming System</code></td> <td><code>epsg_namingsystem</code></td></tr>
<tr><td>Table</td> <td><code>Prime Meridian</code></td> <td><code>epsg_primemeridian</code></td></tr>
<tr><td>Table</td> <td><code>Supersession</code></td> <td><code>epsg_supersession</code></td></tr>
<tr><td>Table</td> <td><code>Unit of Measure</code></td> <td><code>epsg_unitofmeasure</code></td></tr>
<tr><td>Column</td> <td><code>ORDER</code></td> <td><code>coord_axis_order</code></td></tr>
</table>
By default this class auto-detects the schema that contains the EPSG tables and whether the table names are
the ones used by EPSG in the MS-Access version or the PostgreSQL, MySQL or Oracle version of the database.
Consequently it is legal to use the MS-Access table names, which are more readable, in a PostgreSQL database.
<div class="section">Thread safety</div>
All <code>SQLTranslator</code> instances given to the <a href="EPSGFactory.html" title="class in org.apache.sis.referencing.factory.sql"><code>EPSGFactory</code></a> constructor
<strong>shall</strong> be immutable and thread-safe.</div>
<dl>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>0.7</dd>
<p><font size="-1">Defined in the <code>sis-referencing</code> module</font></p>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Constructor</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tr class="altColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.sql.DatabaseMetaData,java.lang.String,java.lang.String)">SQLTranslator</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/sql/DatabaseMetaData.html?is-external=true" title="class or interface in java.sql" class="externalLink">DatabaseMetaData</a>&nbsp;md,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;catalog,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;schema)</code></th>
<td class="colLast">
<div class="block">Creates a new SQL translator for the database described by the given metadata.</div>
</td>
</tr>
</table>
</li>
</ul>
</section>
<!-- ========== METHOD SUMMARY =========== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colSecond" scope="col">Method</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#apply(java.lang.String)">apply</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;sql)</code></th>
<td class="colLast">
<div class="block">Adapts the given SQL statement from the original MS-Access dialect to the dialect of the target database.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getCatalog()">getCatalog</a></span>()</code></th>
<td class="colLast">
<div class="block">Returns the catalog that contains the EPSG schema.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getSchema()">getSchema</a></span>()</code></th>
<td class="colLast">
<div class="block">Returns the schema that contains the EPSG tables.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang" class="externalLink">clone</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang" class="externalLink">finalize</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang" class="externalLink">get­Class</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang" class="externalLink">hash­Code</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang" class="externalLink">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang" class="externalLink">notify­All</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang" class="externalLink">to­String</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long,int)" title="class or interface in java.lang" class="externalLink">wait</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.Function">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true" title="class or interface in java.util.function" class="externalLink">Function</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true#andThen(java.util.function.Function)" title="class or interface in java.util.function" class="externalLink">and­Then</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true#compose(java.util.function.Function)" title="class or interface in java.util.function" class="externalLink">compose</a></code></li>
</ul>
</li>
</ul>
</section>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a id="&lt;init&gt;(java.sql.DatabaseMetaData,java.lang.String,java.lang.String)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>SQLTranslator</h4>
<pre>public&nbsp;SQLTranslator&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/sql/DatabaseMetaData.html?is-external=true" title="class or interface in java.sql" class="externalLink">DatabaseMetaData</a>&nbsp;md,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;catalog,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;schema)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/sql/SQLException.html?is-external=true" title="class or interface in java.sql" class="externalLink">SQLException</a></pre>
<div class="block">Creates a new SQL translator for the database described by the given metadata.
This constructor detects automatically the dialect: the characters to use for quoting identifiers,
and whether the table names are the ones used in the MS-Access database or in the SQL scripts.
<p>If the given catalog or schema name is non-null, then the <a href="https://docs.oracle.com/javase/8/docs/api/java/sql/DatabaseMetaData.html?is-external=true#getTables(java.lang.String,java.lang.String,java.lang.String,java.lang.String%5B%5D)" title="class or interface in java.sql" class="externalLink">search for EPSG tables</a> will be restricted to the catalog or schema of that name.
An empty string (<code>""</code>) means to search for tables without catalog or schema.
A <code>null</code> value means that the catalog or schema should not be used to narrow the search.</p></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>md</code> - information about the database.</dd>
<dd><code>catalog</code> - the catalog where to look for EPSG schema, or <code>null</code> if any.</dd>
<dd><code>schema</code> - the schema where to look for EPSG tables, or <code>null</code> if any.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/sql/SQLException.html?is-external=true" title="class or interface in java.sql" class="externalLink">SQLException</a></code> - if an error occurred while querying the database metadata.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</section>
<!-- ============ METHOD DETAIL ========== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a id="getCatalog()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCatalog</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getCatalog()</pre>
<div class="block">Returns the catalog that contains the EPSG schema. This is the catalog specified at construction time
if it was non-null, or the catalog discovered by the constructor otherwise.
Note that this method may still return <code>null</code> if the EPSG tables were not found or if the database
does not <a href="https://docs.oracle.com/javase/8/docs/api/java/sql/DatabaseMetaData.html?is-external=true#supportsCatalogsInDataManipulation()" title="class or interface in java.sql" class="externalLink">supports catalogs</a>.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the catalog that contains the EPSG schema, or <code>null</code>.</dd>
</dl>
</li>
</ul>
<a id="getSchema()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getSchema</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getSchema()</pre>
<div class="block">Returns the schema that contains the EPSG tables. This is the schema specified at construction time
if it was non-null, or the schema discovered by the constructor otherwise.
Note that this method may still return <code>null</code> if the EPSG tables were not found or if the database
does not <a href="https://docs.oracle.com/javase/8/docs/api/java/sql/DatabaseMetaData.html?is-external=true#supportsSchemasInDataManipulation()" title="class or interface in java.sql" class="externalLink">supports schemas</a>.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the schema that contains the EPSG tables, or <code>null</code>.</dd>
</dl>
</li>
</ul>
<a id="apply(java.lang.String)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>apply</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;apply&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;sql)</pre>
<div class="block">Adapts the given SQL statement from the original MS-Access dialect to the dialect of the target database.
Table and column names may also be replaced.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true#apply(T)" title="class or interface in java.util.function" class="externalLink">apply</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/function/Function.html?is-external=true" title="class or interface in java.util.function" class="externalLink">Function</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>sql</code> - the statement in MS-Access dialect.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the SQL statement adapted to the dialect of the target database.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</section>
</li>
</ul>
</div>
</div>
</main>
<!-- ========= END OF CLASS DATA ========= -->
<footer role="contentinfo">
<nav role="navigation">
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a id="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/SQLTranslator.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../../allclasses.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a id="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</nav>
<p class="legalCopy"><small>Copyright &#169; 2010&#x2013;2019 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</footer>
</body>
</html>