Package org.teiid.translator

Examples of org.teiid.translator.TranslatorException


      tempCalendar.setTime(endTime);
      XMLGregorianCalendar endCalendar = factory.newXMLGregorianCalendar(tempCalendar);
     
      updatedResult = parent.getConnection().getUpdated(objectName, startCalendar, endCalendar);
    } catch (ResourceException e) {
      throw new TranslatorException(e);
    }
  }
View Full Code Here


     
      if (importProcedures) {
        getProcedures(metadataFactory, metadata);
      }
    } catch (DuplicateRecordException e) {
      throw new TranslatorException(e, JDBCPlugin.Util.getString("JDBCMetadataProcessor.not_unique")); //$NON-NLS-1$
    }
   
  }
View Full Code Here

      DataPayload data = new DataPayload();
      data.setType(visitor.getTableName());
      data.setMessageElements(visitor.getMessageElements());
      result = getConnection().create(data);
    } catch (ResourceException e) {
      throw new TranslatorException(e);
    }   
  }
View Full Code Here

            idList.add(sObject.getId());
          }
          Ids = idList.toArray(new String[0]);
        }
      } catch (ResourceException e) {
        throw new TranslatorException(e);
      }
    }
    return Ids;
  }
View Full Code Here

       
            String sequence = name.substring(seqIndex + SEQUENCE.length());
           
            int delimiterIndex = sequence.indexOf(Tokens.DOT);
            if (delimiterIndex == -1) {
              throw new TranslatorException("Invalid name in source sequence format.  Expected <element name>" + SEQUENCE + "<sequence name>.<sequence value>, but was " + name); //$NON-NLS-1$ //$NON-NLS-2$
            }
            String sequenceGroupName = sequence.substring(0, delimiterIndex);
            String sequenceElementName = sequence.substring(delimiterIndex + 1);
               
            NamedTable sequenceGroup = this.getLanguageFactory().createNamedTable(sequenceGroupName, null, null);
View Full Code Here

      String[] Ids = getIDs(((Delete)command).getWhere(), dVisitor);
      if(null != Ids && Ids.length > 0) {
        result = getConnection().delete(Ids);
      }
    } catch (ResourceException e) {
      throw new TranslatorException(e);
    }
  }
View Full Code Here

   
    if (connection instanceof WrappedConnection) {
      try {
        unwrapped = ((WrappedConnection)connection).unwrap();
      } catch (ResourceException e) {
        throw new TranslatorException(QueryPlugin.Util.getString("failed_to_unwrap_connection")); //$NON-NLS-1$
     
    }
   
    try {
      executionFactory.getMetadata(factory, (unwrapped == null) ? connection:unwrapped);
View Full Code Here

          if (!jndiName.equals(this.connectionName)) {
            return ic.lookup(this.connectionName);
          }
        }
      } catch (NamingException e) {
        throw new TranslatorException(e, QueryPlugin.Util.getString("connection_factory_not_found", this.connectionName)); //$NON-NLS-1$
      }        
      }
      return null;
    }
View Full Code Here

        }
  }
 
  List padRow(List row) throws TranslatorException {
        if (row.size() != resultSetCols) {
            throw new TranslatorException(QueryPlugin.Util.getString("ConnectorWorker.ConnectorWorker_result_set_unexpected_columns", new Object[] {proc, new Integer(resultSetCols), new Integer(row.size())})); //$NON-NLS-1$
        }
        if (paramCols == 0) {
          return row;
        }
        List result = new ArrayList(resultSetCols + paramCols);
View Full Code Here

      }

      try {
        result = getConnection().update(updateDataList);
      } catch (ResourceException e) {
        throw new TranslatorException(e);
      }
    }
  }
View Full Code Here

TOP

Related Classes of org.teiid.translator.TranslatorException

Copyright © 2018 www.massapicom. 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.