2
* Drizzle Client & Protocol Library
4
* Copyright (C) 2008 Eric Day (eday@oddments.org)
7
* Use and distribution licensed under the BSD license. See
8
* the COPYING file in this directory for full text.
13
* @brief Result Declarations for Servers
16
#ifndef __DRIZZLE_RESULT_SERVER_H
17
#define __DRIZZLE_RESULT_SERVER_H
24
* @addtogroup drizzle_result_server Result Declarations for Servers
25
* @ingroup drizzle_server_interface
27
* These functions allow you to send result packets over a connection.
32
* Write result packet.
35
drizzle_return_t drizzle_result_write(drizzle_con_st *con,
36
drizzle_result_st *result, bool flush);
39
* Set result row packet size.
42
void drizzle_result_set_row_size(drizzle_result_st *result, size_t size);
45
* Set result row packet size from field and size arrays.
48
void drizzle_result_calc_row_size(drizzle_result_st *result,
49
const drizzle_field_t *field,
53
* Set information string for a result.
56
void drizzle_result_set_eof(drizzle_result_st *result, bool eof);
59
* Set information string for a result.
62
void drizzle_result_set_info(drizzle_result_st *result, const char *info);
65
* Set error string for a result.
68
void drizzle_result_set_error(drizzle_result_st *result, const char *error);
71
* Set server defined error code for a result.
74
void drizzle_result_set_error_code(drizzle_result_st *result,
78
* Set SQL state code for a result.
81
void drizzle_result_set_sqlstate(drizzle_result_st *result,
82
const char *sqlstate);
85
* Set the number of warnings encounted during a command.
88
void drizzle_result_set_warning_count(drizzle_result_st *result,
89
uint16_t warning_count);
92
* Set inet ID of the last command, if any.
95
void drizzle_result_set_insert_id(drizzle_result_st *result,
99
* Set the number of affected rows during the command.
102
void drizzle_result_set_affected_rows(drizzle_result_st *result,
103
uint64_t affected_rows);
106
* Set the number of fields in a result set.
109
void drizzle_result_set_column_count(drizzle_result_st *result,
110
uint16_t column_count);
118
#endif /* __DRIZZLE_RESULT_SERVER_H */