001/*
002// This software is subject to the terms of the Eclipse Public License v1.0
003// Agreement, available at the following URL:
004// http://www.eclipse.org/legal/epl-v10.html.
005// You must accept the terms of that agreement to use this software.
006//
007// Copyright (C) 2011-2012 Pentaho and others
008// All Rights Reserved.
009*/
010package mondrian.spi.impl;
011
012import java.sql.Connection;
013import java.sql.SQLException;
014
015/**
016 * Implementation of {@link mondrian.spi.Dialect} for the Vertica database.
017 *
018 * @author LBoudreau
019 * @since Sept 11, 2009
020 */
021public class VectorwiseDialect extends IngresDialect {
022
023    public static final JdbcDialectFactory FACTORY =
024        new JdbcDialectFactory(
025            VectorwiseDialect.class,
026            DatabaseProduct.VECTORWISE);
027
028    /**
029     * Creates a VectorwiseDialect.
030     *
031     * @param connection Connection
032     */
033    public VectorwiseDialect(Connection connection) throws SQLException {
034        super(connection);
035    }
036
037    @Override
038    public DatabaseProduct getDatabaseProduct() {
039        return DatabaseProduct.VECTORWISE;
040    }
041
042    @Override
043    public boolean supportsResultSetConcurrency(int type, int concurrency) {
044        return false;
045    }
046
047    @Override
048    public boolean requiresHavingAlias() {
049        return true;
050    }
051
052    @Override
053    public boolean requiresAliasForFromQuery() {
054        return true;
055    }
056}
057
058// End VectorwiseDialect.java