Package com.esri.sde.sdk.client

Examples of com.esri.sde.sdk.client.SeQuery.fetch()


     
      // it is not documented in the ArcSDE API how you know there are no more rows to fetch!
      // I'm assuming: query.fetch returns null (empiric tests indicate this assumption is correct).
      boolean allRowsFetched = false;
      while(! allRowsFetched) {
        SeRow row = query.fetch();
        if(row != null) {
          ByteArrayInputStream bytes = row.getBlob(0);
          byte [] buff = new byte[bytes.available()];
          bytes.read(buff);
          String document = new String(buff, Constants.ENCODING);
View Full Code Here


                    testQuery.execute();
                    LOGGER.fine("definition query executed successfully");

                    LOGGER.fine("fetching row to obtain view's types");

                    SeRow testRow = testQuery.fetch();
                    SeColumnDefinition[] colDefs = testRow.getColumns();
                    return colDefs;
                } finally {
                    try {
                        testQuery.close();
View Full Code Here

                             */

                            query.prepareQueryInfo(queryInfo);
                            query.execute();
                            int count = 0;
                            while (query.fetch() != null) {
                                count++;
                            }
                            return count;
                        }
                    }
View Full Code Here

        try {
            query = new SeQuery(scon, rasterColumns, new SeSqlConstruct(rasterTable));
            query.prepareQuery();
            query.execute();

            SeRow row = query.fetch();
            while (row != null) {
                rasterAttributes = row.getRaster(0);
                rasterAttList.addFirst(rasterAttributes);
                row = query.fetch();
            }
View Full Code Here

            SeRow row = query.fetch();
            while (row != null) {
                rasterAttributes = row.getRaster(0);
                rasterAttList.addFirst(rasterAttributes);
                row = query.fetch();
            }
        } catch (SeException se) {
            throw new ArcSdeException("Error fetching raster attributes for " + rasterTable, se);
        } finally {
            if (query != null) {
View Full Code Here

            long bandId;
            ByteArrayInputStream colorMapIS;
            DataBuffer colorMapData;
            IndexColorModel colorModel;

            SeRow row = query.fetch();
            while (row != null) {
                bandId = ((Number) row.getObject(0)).longValue();
                colorMapIS = row.getBlob(1);

                colorMapData = readColorMap(colorMapIS);
View Full Code Here

                colorMapData = readColorMap(colorMapIS);
                colorModel = RasterUtils.sdeColorMapToJavaColorModel(colorMapData, bitsPerSample);

                colorMaps.put(Long.valueOf(bandId), colorModel);

                row = query.fetch();
            }
        } catch (SeException e) {
            throw new ArcSdeException("Error fetching colormap data for column " + rasterColumnId
                    + " from table " + auxTableName, e);
        } finally {
View Full Code Here

                query = new SeQuery(scon, new String[] { "OWNER" }, sqlCons);
                query.prepareQuery();
            }
            query.execute();

            SeRow row = query.fetch();
            if (row == null) {
                throw new IllegalArgumentException("No raster column registered with id "
                        + rasterColumnId);
            }
            owner = row.getString(0);
View Full Code Here

                rowQuery.setSpatialConstraints(SeQuery.SE_OPTIMIZE, false, spatFilters);
                rowQuery.prepareQuery();
                rowQuery.execute();

                // fetch some rows
                rowQuery.fetch();
                rowQuery.fetch();
                rowQuery.fetch();

                SeQuery countQuery = new SeQuery(connection, columns, sql);
                countQuery.setSpatialConstraints(SeQuery.SE_OPTIMIZE, true, spatFilters);
View Full Code Here

                rowQuery.prepareQuery();
                rowQuery.execute();

                // fetch some rows
                rowQuery.fetch();
                rowQuery.fetch();
                rowQuery.fetch();

                SeQuery countQuery = new SeQuery(connection, columns, sql);
                countQuery.setSpatialConstraints(SeQuery.SE_OPTIMIZE, true, spatFilters);
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.