GRASS Programmer's Manual
6.4.2(2012)
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
d_bindupdate.c
Go to the documentation of this file.
1
15
#include <grass/dbmi.h>
16
#include "
macros.h
"
17
#include "
dbstubs.h
"
18
25
int
db_d_bind_update
()
26
{
27
dbToken token;
28
dbCursor *cursor;
29
int
stat;
30
int
ncols;
31
32
/* get the arg(s) */
33
DB_RECV_TOKEN
(&token);
34
cursor = (dbCursor *)
db_find_token
(token);
35
if
(cursor ==
NULL
|| !
db_test_cursor_type_update
(cursor)) {
36
db_error
(
"** not an update cursor **"
);
37
DB_SEND_FAILURE
();
38
return
DB_FAILED;
39
}
40
DB_RECV_SHORT_ARRAY
(&cursor->column_flags, &ncols);
41
if
(!
db_test_cursor_any_column_flag
(cursor)) {
42
db_error
(
"** no columns set in cursor for binding **"
);
43
DB_SEND_FAILURE
();
44
return
DB_FAILED;
45
}
46
47
/* call the procedure */
48
stat =
db_driver_bind_update
(cursor);
49
50
/* send the return code */
51
if
(stat != DB_OK) {
52
DB_SEND_FAILURE
();
53
return
DB_OK;
54
}
55
DB_SEND_SUCCESS
();
56
57
/* no results */
58
return
DB_OK;
59
}
lib
db
dbmi_driver
d_bindupdate.c
Generated on Sun Sep 9 2012 18:55:30 for GRASS Programmer's Manual by
1.8.1.2