Examples of sourceAttributes()


Examples of com.webobjects.eoaccess.EORelationship.sourceAttributes()

                    if( (! this.isSinglePrimaryKeyAttribute(attribute)) && (columnNameDictionary.objectForKey(destinationTableName + "." + attribute.columnName()) != null) ) {
                      columnNameDictionary.setObjectForKey(attribute.columnName(), destinationTableName + "." + attribute.columnName());
                      EOSQLExpression expression = this._expressionForString("create index " + destinationTableName + " " + attribute.columnName());
                      if(expression != null) primaryKeyConstraintExpressions.addObject( expression );
                    }
                    if( (! relationship.isCompound() ) && (relationship.sourceAttributes().count() == 1) && (relationship.destinationAttributes().count() == 1) ) {
                      String semantics;
                      switch(relationship.joinSemantic()) {
                        case EORelationship.FullOuterJoin: // '\001'
                        case EORelationship.LeftOuterJoin: // '\002'
                        case EORelationship.RightOuterJoin: // '\003'
View Full Code Here

Examples of com.webobjects.eoaccess.EORelationship.sourceAttributes()

                         
                        default:
                          semantics = "=";
                          break;
                      }
                      String sourceColumn = ((EOAttribute)relationship.sourceAttributes().objectAtIndex(0)).columnName();
                      String destinationColumn = ((EOAttribute)relationship.destinationAttributes().objectAtIndex(0)).columnName();
                      EOSQLExpression expression = this._expressionForString("delete from _SYS_RELATIONSHIP where relationshipName = '" + relationship.name() + "' and source_table = '" + tableName + "' ");
                      if(expression != null) primaryKeyConstraintExpressions.addObject( expression );
                      expression = this._expressionForString("insert into _SYS_RELATIONSHIP (relationshipName, source_table, source_column, dest_table, dest_column, operator, one_to_many) values ('" + relationship.name() + "','" + tableName + "','" + sourceColumn + "','" + destinationTableName + "','" + destinationColumn + "','" + semantics + "'," + (relationship.isToMany() ? 1 : 0) + ")");
                      if(expression != null) primaryKeyConstraintExpressions.addObject( expression );
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.