Examples of JDBCRelationMetaData


Examples of org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCRelationMetaData

/* 1444 */         if (this.joinedAliases.add(joinAlias))
/*      */         {
/* 1446 */           JDBCAbstractCMRFieldBridge cmrField = (JDBCAbstractCMRFieldBridge)path.getCMRField(i);
/* 1447 */           JDBCAbstractEntityBridge joinEntity = (JDBCAbstractEntityBridge)cmrField.getRelatedEntity();
/*      */
/* 1449 */           JDBCRelationMetaData relation = cmrField.getMetaData().getRelationMetaData();
/*      */
/* 1451 */           String join = path.innerJoin ? " INNER JOIN " : " LEFT OUTER JOIN ";
/*      */
/* 1453 */           if (relation.isTableMappingStyle())
/*      */           {
/* 1455 */             String relTableAlias = this.aliasManager.getRelationTableAlias(curPath);
/* 1456 */             sql.append(join).append(cmrField.getQualifiedTableName()).append(' ').append(relTableAlias).append(" ON ");
/*      */
/* 1461 */             SQLUtil.getRelationTableJoinClause(cmrField, leftAlias, relTableAlias, sql);
View Full Code Here

Examples of org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCRelationMetaData

/*  482 */       LeftJoinCMRNode node = (LeftJoinCMRNode)onFindCMRNodes.get(i);
/*  483 */       JDBCCMRFieldBridge cmrField = node.cmrField;
/*  484 */       JDBCEntityBridge relatedEntity = cmrField.getRelatedJDBCEntity();
/*  485 */       String relatedAlias = aliasManager.getAlias(node.path);
/*      */
/*  487 */       JDBCRelationMetaData relation = cmrField.getMetaData().getRelationMetaData();
/*  488 */       if (relation.isTableMappingStyle())
/*      */       {
/*  490 */         String relTableAlias = aliasManager.getRelationTableAlias(node.path);
/*  491 */         sb.append(" LEFT OUTER JOIN ").append(cmrField.getQualifiedTableName()).append(' ').append(relTableAlias).append(" ON ");
/*      */
/*  496 */         SQLUtil.getRelationTableJoinClause(cmrField, alias, relTableAlias, sb);
View Full Code Here

Examples of org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCRelationMetaData

/*     */
/*  74 */     JDBCAbstractCMRFieldBridge[] cmrFields = this.entity.getCMRFields();
/*  75 */     for (int i = 0; i < cmrFields.length; i++)
/*     */     {
/*  77 */       JDBCAbstractCMRFieldBridge cmrField = cmrFields[i];
/*  78 */       JDBCRelationMetaData relationMetaData = cmrField.getMetaData().getRelationMetaData();
/*  79 */       if ((!relationMetaData.isTableMappingStyle()) || (relationMetaData.isTableDropped()))
/*     */         continue;
/*  81 */       if (!relationMetaData.getRemoveTable())
/*     */         continue;
/*  83 */       boolean dropped = dropTable(relationMetaData.getDataSource(), cmrField.getQualifiedTableName());
/*  84 */       if (!dropped)
/*     */       {
/*  86 */         success = false;
/*     */       }
/*     */       else
/*     */       {
/*  90 */         relationMetaData.setTableDropped();
/*     */       }
/*     */
/*     */     }
/*     */
/*  96 */     if (this.entityMetaData.getRemoveTable())
View Full Code Here

Examples of org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCRelationMetaData

/*  62 */     this.schema = schema;
/*  63 */     this.tableId = tableId;
/*  64 */     this.leftField = leftField;
/*  65 */     this.rightField = rightField;
/*     */
/*  67 */     JDBCRelationMetaData metadata = leftField.getMetaData().getRelationMetaData();
/*  68 */     this.ds = metadata.getDataSource();
/*  69 */     this.tableName = SQLUtil.fixTableName(metadata.getDefaultTableName(), this.ds);
/*     */
/*  71 */     this.log = Logger.getLogger(getClass().getName() + "." + this.tableName);
/*     */
/*  75 */     this.insertSql = ("insert into " + this.tableName + " (");
/*     */
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.