use of com.liferay.portal.kernel.dao.db.DB in project liferay-ide by liferay.
the class RosterMemberLocalServiceBaseImpl method runSQL.
/**
* Performs a SQL query.
*
* @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);
}
}
use of com.liferay.portal.kernel.dao.db.DB in project liferay-ide by liferay.
the class RosterMemberServiceBaseImpl method runSQL.
/**
* Performs a SQL query.
*
* @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);
}
}
use of com.liferay.portal.kernel.dao.db.DB in project liferay-blade-samples by liferay.
the class CountryLocalServiceBaseImpl method runSQL.
/**
* Performs a SQL query.
*
* @param sql the sql query
*/
protected void runSQL(String sql) {
try {
DataSource dataSource = countryPersistence.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);
}
}
use of com.liferay.portal.kernel.dao.db.DB in project liferay-blade-samples by liferay.
the class FooServiceBaseImpl method runSQL.
/**
* Performs a SQL query.
*
* @param sql the sql query
*/
protected void runSQL(String sql) {
try {
DataSource dataSource = fooPersistence.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);
}
}
use of com.liferay.portal.kernel.dao.db.DB in project liferay-ide by liferay.
the class ClubLocalServiceBaseImpl method runSQL.
/**
* Performs a SQL query.
*
* @param sql the sql query
*/
protected void runSQL(String sql) {
try {
DataSource dataSource = clubPersistence.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);
}
}
Aggregations