List of usage examples for com.liferay.portal.kernel.util PortalUtil transformSQL
public static String transformSQL(String sql)
From source file:com.liferay.site.navigation.service.base.SiteNavigationMenuLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.// w w w.j a v a 2 s . c om * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = siteNavigationMenuPersistence.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.service.base.SiteFriendlyURLLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w w w .ja v a 2 s. c om * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = siteFriendlyURLPersistence.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.social.activity.customizer.service.base.CustomSocialActivitySetLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.// w ww.j av a 2 s . c om * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = customSocialActivitySetPersistence.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.subscription.service.base.SubscriptionLocalServiceBaseImpl.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 = subscriptionPersistence.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.sync.service.base.SyncDeviceLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./*ww w . j ava 2s. co m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = syncDevicePersistence.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.trash.service.base.TrashEntryLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./*from ww w .ja v a2 s . c o m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = trashEntryPersistence.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.trash.service.base.TrashVersionLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query./* w w w . j a va2s . co m*/ * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = trashVersionPersistence.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.video.library.service.base.VideoLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.// w ww .java 2s. c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = videoPersistence.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.wiki.service.base.WikiNodeLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w w w .jav a2 s . c om * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = wikiNodePersistence.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.wiki.service.base.WikiPageLocalServiceBaseImpl.java
License:Open Source License
/** * Performs a SQL query.//from w w w.ja v a 2 s . c o m * * @param sql the sql query */ protected void runSQL(String sql) { try { DataSource dataSource = wikiPagePersistence.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); } }