List of usage examples for com.liferay.portal.kernel.util PortalUtil transformSQL
public static String transformSQL(String sql)
From source file:com.liferay.roster.service.base.RosterLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./*from w w w . j a v a 2 s . co m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = rosterPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.roster.service.base.RosterMemberLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//ww w .j a v a 2 s. com * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = rosterMemberPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.AssetLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./*from w ww . j a v a 2 s . c om*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = assetPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.CheckoutLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./*from w w w. j a v a 2 s . co m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = checkoutPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.DefinitionLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.// www .j av a 2 s.c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = definitionPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.SAMTodoItemLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./* w ww .j a va 2 s . co m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = samTodoItemPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.SAMTodoListLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from www .ja v a2 s. c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = samTodoListPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.samplealloymvc.service.base.TypeLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w w w . j a v a 2s . c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = typePersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.school.service.base.CourseLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w ww .j av a 2 s . c om * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = coursePersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }
From source file:com.liferay.site.navigation.service.base.SiteNavigationMenuItemLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w w w .j av a 2s . c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = siteNavigationMenuItemPersistence.getDataSource(); DB db = DBManagerUtil.getDB(); sql = db.buildSQL(sql); sql = PortalUtil.transformSQL(sql); SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource, sql); sqlUpdate.update(); } catch (Exception e) { throw new SystemException(e); } }