亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? updatableresultset.java

?? jsp數(shù)據(jù)庫系統(tǒng)
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
/*
   Copyright (C) 2002 MySQL AB

      This program is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public License as published by
      the Free Software Foundation; either version 2 of the License, or
      (at your option) any later version.

      This program is distributed in the hope that it will be useful,
      but WITHOUT ANY WARRANTY; without even the implied warranty of
      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      GNU General Public License for more details.

      You should have received a copy of the GNU General Public License
      along with this program; if not, write to the Free Software
      Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA

 */
package com.mysql.jdbc;

import java.io.UnsupportedEncodingException;

import java.math.BigDecimal;

import java.sql.SQLException;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;


/**
 * A result set that is updatable.
 *
 * @author Mark Matthews
 */
public class UpdatableResultSet extends ResultSet {
    /** Marker for 'stream' data when doing INSERT rows */
    private final static byte[] STREAM_DATA_MARKER = "** STREAM DATA **"
        .getBytes();

    /** List of primary keys */
    private List primaryKeyIndicies = null;

    /** PreparedStatement used to delete data */
    private com.mysql.jdbc.PreparedStatement deleter = null;

    /** PreparedStatement used to insert data */
    private com.mysql.jdbc.PreparedStatement inserter = null;

    /** PreparedStatement used to refresh data */
    private com.mysql.jdbc.PreparedStatement refresher;

    /** PreparedStatement used to delete data */
    private com.mysql.jdbc.PreparedStatement updater = null;
    private SingleByteCharsetConverter charConverter;
    private String charEncoding;
    private String deleteSQL = null;
    private String insertSQL = null;
    private String quotedIdChar = null;
    private String refreshSQL = null;
    private String tableName;

    /** SQL for in-place modifcation */
    private String updateSQL = null;

    /** What is the default value for the column? */
    private byte[][] defaultColumnValue;

    /** The binary data for the 'current' row */
    private byte[][] savedCurrentRow;

    /** Is this result set updateable? */
    private boolean isUpdatable = false;

    /**
     * Creates a new UpdatableResultSet object.
     *
     * @param updateCount DOCUMENT ME!
     * @param updateID DOCUMENT ME!
     */
    public UpdatableResultSet(long updateCount, long updateID) {
        super(updateCount, updateID);
    }

    // ****************************************************************
    //
    //                       END OF PUBLIC INTERFACE
    //
    // ****************************************************************

    /**
     * Create a new ResultSet - Note that we create ResultSets to represent the
     * results of everything.
     *
     * @param catalog the database in use when this result set was created
     * @param fields an array of Field objects (basically, the ResultSet
     *        MetaData)
     * @param rows Vector of the actual data
     * @param conn the status string returned from the back end
     *
     * @throws SQLException DOCUMENT ME!
     */
    public UpdatableResultSet(String catalog, Field[] fields, RowData rows,
        com.mysql.jdbc.Connection conn) throws SQLException {
        super(catalog, fields, rows, conn);
        isUpdatable = checkUpdatability();
    }

    /**
     * Creates a new UpdatableResultSet object.
     *
     * @param fields DOCUMENT ME!
     * @param rows DOCUMENT ME!
     *
     * @throws SQLException DOCUMENT ME!
     */
    public UpdatableResultSet(Field[] fields, RowData rows)
        throws SQLException {
        super(fields, rows);
        isUpdatable = checkUpdatability();
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Determine if the cursor is after the last row in the result  set.
     * </p>
     *
     * @return true if after the last row, false otherwise.  Returns false when
     *         the result set contains no rows.
     *
     * @exception SQLException if a database-access error occurs.
     */
    public synchronized boolean isAfterLast() throws SQLException {
        return super.isAfterLast();
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Determine if the cursor is before the first row in the result  set.
     * </p>
     *
     * @return true if before the first row, false otherwise. Returns false
     *         when the result set contains no rows.
     *
     * @exception SQLException if a database-access error occurs.
     */
    public synchronized boolean isBeforeFirst() throws SQLException {
        return super.isBeforeFirst();
    }

    /**
     * JDBC 2.0 Return the concurrency of this result set.  The concurrency
     * used is determined by the statement that created the result set.
     *
     * @return the concurrency type, CONCUR_READ_ONLY, etc.
     *
     * @exception SQLException if a database-access error occurs
     */
    public int getConcurrency() throws SQLException {
        return (isUpdatable ? CONCUR_UPDATABLE : CONCUR_READ_ONLY);
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Determine if the cursor is on the first row of the result set.
     * </p>
     *
     * @return true if on the first row, false otherwise.
     *
     * @exception SQLException if a database-access error occurs.
     */
    public synchronized boolean isFirst() throws SQLException {
        return super.isFirst();
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Determine if the cursor is on the last row of the result set.    Note:
     * Calling isLast() may be expensive since the JDBC driver might need to
     * fetch ahead one row in order to determine  whether the current row is
     * the last row in the result set.
     * </p>
     *
     * @return true if on the last row, false otherwise.
     *
     * @exception SQLException if a database-access error occurs.
     */
    public synchronized boolean isLast() throws SQLException {
        return super.isLast();
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Move to an absolute row number in the result set.
     * </p>
     * 
     * <p>
     * If row is positive, moves to an absolute row with respect to the
     * beginning of the result set.  The first row is row 1, the second is row
     * 2, etc.
     * </p>
     * 
     * <p>
     * If row is negative, moves to an absolute row position with respect to
     * the end of result set.  For example, calling absolute(-1) positions the
     * cursor on the last row, absolute(-2) indicates the next-to-last row,
     * etc.
     * </p>
     * 
     * <p>
     * An attempt to position the cursor beyond the first/last row in the
     * result set, leaves the cursor before/after the first/last row,
     * respectively.
     * </p>
     * 
     * <p>
     * Note: Calling absolute(1) is the same as calling first(). Calling
     * absolute(-1) is the same as calling last().
     * </p>
     *
     * @param row DOCUMENT ME!
     *
     * @return true if on the result set, false if off.
     *
     * @exception SQLException if a database-access error occurs, or  row is 0,
     *            or result set type is TYPE_FORWARD_ONLY.
     */
    public synchronized boolean absolute(int row) throws SQLException {
        return super.absolute(row);
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Moves to the end of the result set, just after the last row.  Has no
     * effect if the result set contains no rows.
     * </p>
     *
     * @exception SQLException if a database-access error occurs, or result set
     *            type is TYPE_FORWARD_ONLY.
     */
    public synchronized void afterLast() throws SQLException {
        super.afterLast();
    }

    /**
     * JDBC 2.0
     * 
     * <p>
     * Moves to the front of the result set, just before the first row. Has no
     * effect if the result set contains no rows.
     * </p>
     *
     * @exception SQLException if a database-access error occurs, or result set
     *            type is TYPE_FORWARD_ONLY
     */
    public synchronized void beforeFirst() throws SQLException {
        super.beforeFirst();
    }

    /**
     * JDBC 2.0 The cancelRowUpdates() method may be called after calling an
     * updateXXX() method(s) and before calling updateRow() to rollback  the
     * updates made to a row.  If no updates have been made or  updateRow()
     * has already been called, then this method has no  effect.
     *
     * @exception SQLException if a database-access error occurs, or if called
     *            when on the insert row.
     */
    public synchronized void cancelRowUpdates() throws SQLException {
        if (doingUpdates) {
            doingUpdates = false;
            updater.clearParameters();
        }
    }

    /**
     * After this call, getWarnings returns null until a new warning is
     * reported for this ResultSet
     *
     * @exception java.sql.SQLException if a database access error occurs
     */
    public synchronized void clearWarnings() throws java.sql.SQLException {
        warningChain = null;
    }

    /**
     * In some cases, it is desirable to immediately release a ResultSet
     * database and JDBC resources instead of waiting for this to happen when
     * it is automatically closed.  The close method provides this immediate
     * release.
     * 
     * <p>
     * <B>Note:</B> A ResultSet is automatically closed by the Statement the
     * Statement that generated it when that Statement is closed, re-executed,
     * or is used to retrieve the next result from a sequence of multiple
     * results.  A ResultSet is also automatically closed when it is garbage
     * collected.
     * </p>
     *
     * @exception java.sql.SQLException if a database access error occurs
     */
    public synchronized void close() throws java.sql.SQLException {
        super.close();
    }

    /**
     * JDBC 2.0 Delete the current row from the result set and the underlying
     * database.  Cannot be called when on the insert row.
     *
     * @exception SQLException if a database-access error occurs, or if called
     *            when on the insert row.
     * @throws SQLException if the ResultSet is not updatable or some other
     *         error occurs
     */
    public synchronized void deleteRow() throws SQLException {
        if (!isUpdatable) {
            throw new NotUpdatable();
        }

        if (onInsertRow) {
            throw new SQLException(
                "Can not call deleteRow() when on insert row");
        } else if (rowData.size() == 0) {
            throw new SQLException("Can't deleteRow() on empty result set");
        } else if (isBeforeFirst()) {
            throw new SQLException(
                "Before start of result set. Can not call deleteRow().");
        } else if (isAfterLast()) {
            throw new SQLException(
                "After end of result set. Can not call deleteRow().");
        }

        if (deleter == null) {
            if (deleteSQL == null) {
                generateStatements();
            }

            deleter = (com.mysql.jdbc.PreparedStatement) connection
                .prepareStatement(deleteSQL);
            
            if (deleter.getMaxRows() != 0) {
            	deleter.setMaxRows(0);
            }
        }

        deleter.clearParameters();

        String characterEncoding = null;

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区精品在线观看| 亚洲一区二区三区在线看| 国产精品激情偷乱一区二区∴| av一二三不卡影片| 久久只精品国产| 久久超级碰视频| 日韩欧美国产麻豆| 日韩成人免费看| 欧美一级在线视频| 蜜臂av日日欢夜夜爽一区| 91精品国产高清一区二区三区| 婷婷久久综合九色综合伊人色| 亚洲国产精品高清| 视频一区中文字幕国产| 欧美精品 国产精品| 亚洲第一会所有码转帖| 欧美精选在线播放| 日本不卡一二三区黄网| 日韩午夜中文字幕| 极品少妇xxxx精品少妇| 久久久久国产一区二区三区四区| 狠狠色丁香久久婷婷综| 欧美韩国日本一区| av动漫一区二区| 一区二区三区精品在线观看| 欧美日韩在线观看一区二区| 日韩高清不卡一区二区三区| 日韩精品一区二区三区四区 | 久久影院午夜片一区| 国产美女一区二区| 国产日产亚洲精品系列| 国产自产v一区二区三区c| 亚洲国产另类av| 26uuu久久天堂性欧美| 欧美日韩免费在线视频| 青青青伊人色综合久久| 精品少妇一区二区三区在线视频| 国产麻豆精品久久一二三| 国产日韩精品一区二区三区在线| 成人国产在线观看| 亚洲一级在线观看| 欧美成人午夜电影| 成人国产精品免费观看视频| 一区二区三区欧美视频| 日韩一级黄色大片| 国产成人av一区| 一区二区三区四区五区视频在线观看| 欧美日韩黄色一区二区| 国产资源精品在线观看| 亚洲色图视频网| 91麻豆精品国产91久久久久| 国产麻豆成人传媒免费观看| ...xxx性欧美| 在线播放日韩导航| 国产激情偷乱视频一区二区三区| 亚洲色图一区二区| 欧美大片在线观看| 99精品视频中文字幕| 天堂久久久久va久久久久| 久久综合九色综合97_久久久| 99久久精品免费看| 麻豆91精品视频| 日韩一区在线看| 日韩一卡二卡三卡| 欧洲一区二区三区在线| 欧美优质美女网站| 色悠悠亚洲一区二区| 日韩三级在线免费观看| 中文字幕精品一区二区三区精品| 91美女精品福利| 久久精品99久久久| 亚洲欧美韩国综合色| 日韩欧美久久一区| 91视视频在线观看入口直接观看www | 国产成人免费网站| 伊人色综合久久天天| 精品伦理精品一区| 91黄色免费观看| 国产精品综合久久| 亚洲成av人影院| 欧美国产欧美综合| 777xxx欧美| 一本一道久久a久久精品| 精品一区二区三区免费视频| 夜夜精品视频一区二区| 日本一区免费视频| 91精品国产福利在线观看| 99re这里只有精品视频首页| 激情文学综合插| 午夜精品视频一区| 亚洲欧美日韩在线播放| 久久久国产午夜精品| 欧美一级二级三级蜜桃| 色婷婷一区二区| 成人美女视频在线观看| 久久99国产乱子伦精品免费| 亚洲一区二区视频在线| 亚洲欧洲国产日本综合| 久久久噜噜噜久噜久久综合| 91精品婷婷国产综合久久 | 成人网男人的天堂| 精品一区二区三区在线播放| 天天射综合影视| 夜色激情一区二区| 亚洲日本免费电影| 国产精品美女一区二区三区| 精品sm在线观看| 欧美一级片在线| 欧美日韩国产精品自在自线| 色又黄又爽网站www久久| 不卡的电影网站| 国产精品乡下勾搭老头1| 精彩视频一区二区| 在线一区二区观看| 国产一区二区日韩精品| 亚洲欧美另类图片小说| 国产精品毛片高清在线完整版| 久久久久久久综合色一本| 日韩欧美色综合网站| 欧美一区二区三区小说| 9191久久久久久久久久久| 欧美日精品一区视频| 欧美三级蜜桃2在线观看| 亚洲日本在线天堂| 日韩三级伦理片妻子的秘密按摩| 欧美日韩一区二区三区四区五区 | 欧美一区二区免费观在线| 欧美日韩日日骚| 在线不卡的av| 日韩一二三四区| 精品久久人人做人人爽| 日韩精品中文字幕在线不卡尤物 | 亚洲一区二区三区四区不卡| 亚洲精品乱码久久久久久黑人| 亚洲欧美日韩系列| 亚洲婷婷综合色高清在线| 亚洲视频在线一区二区| 亚洲精品免费看| 亚洲高清免费一级二级三级| 性久久久久久久久| 日本不卡一二三| 强制捆绑调教一区二区| 久久99精品久久久久久| 国产黄色成人av| 成人高清av在线| 风间由美中文字幕在线看视频国产欧美| 国产日韩视频一区二区三区| 亚洲免费观看视频| 伊人婷婷欧美激情| 亚洲超碰精品一区二区| 日本最新不卡在线| 精品一区二区成人精品| 国产黄色91视频| 99re这里只有精品视频首页| 91国产免费看| 欧美丰满一区二区免费视频| 日韩一区二区三区电影在线观看 | 9191精品国产综合久久久久久 | 日韩欧美二区三区| 久久精品一区二区三区av| 国产精品免费视频观看| 亚洲精品乱码久久久久久| 日韩中文字幕麻豆| 国内精品国产三级国产a久久| 成人免费三级在线| 在线视频你懂得一区二区三区| 欧美电影一区二区三区| 欧美精品一区二区在线播放| 国产精品麻豆视频| 亚洲综合成人在线| 精品中文字幕一区二区| 成人av免费在线| 欧美日韩国产天堂| 久久久亚洲午夜电影| 日韩一区在线看| 免费在线看成人av| 成人18视频日本| 欧美日韩国产美| 久久精品视频在线看| 亚洲永久精品大片| 正在播放亚洲一区| 久久成人精品无人区| 国内成+人亚洲+欧美+综合在线| 日本麻豆一区二区三区视频| 粉嫩在线一区二区三区视频| 91亚洲国产成人精品一区二区三| 在线不卡a资源高清| 欧美—级在线免费片| 午夜免费久久看| 国产99久久久久久免费看农村| 在线这里只有精品| 亚洲精品在线观看网站| 亚洲精品国产a| 国产在线播精品第三| 色999日韩国产欧美一区二区| 精品成人佐山爱一区二区| 亚洲激情校园春色| 国产高清精品在线| 88在线观看91蜜桃国自产| 国产精品卡一卡二|