Lines Matching defs:statement

50 //     After grabbing the statement for execution (in SQLTransactionBackend::getNextStatement()):
56 // Then we execute the statement in SQLTransactionBackend::runCurrentStatementAndGetNextState().
63 // After we're done executing the statement (in SQLTransactionBackend::getNextStatement()):
65 // When we're done executing, we'll grab the next statement. But before we
75 const String& statement, const Vector<SQLValue>& arguments, int permissions)
77 return adoptRefWillBeNoop(new SQLStatementBackend(frontend, statement, arguments, permissions));
81 const String& statement, const Vector<SQLValue>& arguments, int permissions)
83 , m_statement(statement.isolatedCopy())
118 // If we're re-running this statement after a quota violation, we need to clear that error now
130 SQLiteStatement statement(*database, m_statement);
131 int result = statement.prepare();
134 WTF_LOG(StorageAPI, "Unable to verify correctness of statement %s - error %i (%s)", m_statement.ascii().data(), result, database->lastErrorMsg());
136 m_error = SQLErrorData::create(SQLError::DATABASE_ERR, "could not prepare statement", result, "interrupted");
138 m_error = SQLErrorData::create(SQLError::SYNTAX_ERR, "could not prepare statement", result, database->lastErrorMsg());
143 // FIXME: If the statement uses the ?### syntax supported by sqlite, the bind parameter count is very likely off from the number of question marks.
145 if (statement.bindParameterCount() != m_arguments.size()) {
147 m_error = SQLErrorData::create(SQLError::SYNTAX_ERR, "number of '?'s in statement string does not match argument count");
153 result = statement.bindValue(i + 1, m_arguments[i]);
160 WTF_LOG(StorageAPI, "Failed to bind value index %i to statement for query '%s'", i + 1, m_statement.ascii().data());
168 result = statement.step();
170 int columnCount = statement.columnCount();
174 rows->addColumn(statement.getColumnName(i));
178 rows->addResult(statement.getColumnValue(i));
180 result = statement.step();
193 // Return the Quota error - the delegate will be asked for more space and this statement might be re-run
198 m_error = SQLErrorData::create(SQLError::CONSTRAINT_ERR, "could not execute statement due to a constaint failure", result, database->lastErrorMsg());
202 m_error = SQLErrorData::create(SQLError::DATABASE_ERR, "could not execute statement", result, database->lastErrorMsg());