Package com.ipc.oce.query

Examples of com.ipc.oce.query.OCQueryResult


      case OCType.OCT_REF_ENUM: {
        res = new OCEnumRef(object);
        break;
      }
      case OCType.OCT_QUERY_RESULT: {
        res = new OCQueryResult(object);
        break;
      }
      case OCType.OCT_ARRAY: {
        res = new OCArray(object);
        break;
View Full Code Here


   
    // set parameters
    query.setParameter("NUM_A", new OCVariant(number));
    query.setParameter("DATE_A", new OCVariant(docDate));
   
    OCQueryResult result = query.execute();
    OCQueryResultSelection selection = result.choose();
    OCDocumentRef ref = null;
    if (selection.next()) {
      ref = new OCDocumentRef(selection.getObject(0));
    } else {
      ref = emptyRef();
View Full Code Here

    OCApp instance = OCApp.getInstance(getAssociatedSessionID());
    OCQuery query = instance.newQuery("SELECT Doc.Ref FROM Document." + managerName + " AS Doc WHERE Doc.Number = &NUM_A");
   
    query.setParameter("NUM_A", new OCVariant(number));
   
    OCQueryResult result = query.execute();
    OCQueryResultSelection selection = result.choose();
    int selectionSZ = selection.size();
    List<OCDocumentRef> refList = new ArrayList<OCDocumentRef>(selectionSZ);
    while (selection.next()) {
      refList.add(new OCDocumentRef(selection.getObject(0)));
    }
View Full Code Here

 
  @Test
  public void getResultAndUnload() throws JIException {
    QueryTemplate qt = new QueryTemplate(app);
    OCQueryResultSelection selection = qt.queryForSelection("SELECT * FROM Catalog.Валюты");
    OCQueryResult result = selection.getOwner();
    OCValueTable vt = result.unload();
    assertTrue(vt.size() > 0);
    OCValueTableColumnCollection vtCC = vt.getColumns();
    int vtCCSZ = vtCC.size();
    assertTrue(vtCCSZ > 0);
    System.out.println(vt.size());
View Full Code Here

    catSel.next();
    OCCatalogRef orgRef = catSel.getRef();
   
    query.setParameter("Организация", new OCVariant(orgRef));
   
    OCQueryResult result = query.execute();
    OCValueTable table = result.unload();
    System.out.println(table.listColumns());
   
    OCStructure structure = app.newStructure();
    structure.insert("ТаблицаДанных", table);
   
View Full Code Here

 
  public boolean execute() throws SQLException {
    ResultSet rSet = null;
    boolean res = false;
    try {
      OCQueryResult result = getOceStatement().execute();
      rSet = new OCEResultSet(result, this);
      if (rSet != null) {
        res = true;
        lastVisitedResultSet = rSet;
      }
View Full Code Here

 
  public ResultSet executeQuery(String query) throws SQLException {
    ResultSet rSet = null;
    try {
      oceStatement.setText(query);
      OCQueryResult result = oceStatement.execute();
      rSet = new OCEResultSet(result, this);
      lastVisitedResultSet = rSet;
    } catch (JIException e) {
      throw new SQLException(e.toString());
    }
View Full Code Here

TOP

Related Classes of com.ipc.oce.query.OCQueryResult

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.