db_postgres/dbase.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef DBASE_H
00035 #define DBASE_H
00036
00037 #include "../../db/db_con.h"
00038 #include "../../db/db_res.h"
00039 #include "../../db/db_key.h"
00040 #include "../../db/db_op.h"
00041 #include "../../db/db_val.h"
00042
00043
00044
00045
00046
00047 db_con_t* db_postgres_init(const str* _url);
00048
00049
00050
00051
00052 void db_postgres_close(db_con_t* _h);
00053
00054
00055
00056
00057 int db_postgres_store_result(const db_con_t* _h, db_res_t** _r);
00058
00059
00060
00061
00062
00063 int db_postgres_free_result(db_con_t* _h, db_res_t* _r);
00064
00065
00066
00067
00068
00069 int db_postgres_query(const db_con_t* _h, const db_key_t* _k, const db_op_t* _op,
00070 const db_val_t* _v, const db_key_t* _c, const int _n, const int _nc,
00071 const db_key_t _o, db_res_t** _r);
00072
00073
00074
00075
00076 int db_postgres_raw_query(const db_con_t* _h, const str* _s, db_res_t** _r);
00077
00078
00079
00080
00081
00082 int db_postgres_insert(const db_con_t* _h, const db_key_t* _k, const db_val_t* _v,
00083 const int _n);
00084
00085
00086
00087
00088
00089 int db_postgres_delete(const db_con_t* _h, const db_key_t* _k, const db_op_t* _o,
00090 const db_val_t* _v, const int _n);
00091
00092
00093
00094
00095
00096 int db_postgres_update(const db_con_t* _h, const db_key_t* _k, const db_op_t* _o,
00097 const db_val_t* _v, const db_key_t* _uk, const db_val_t* _uv, const int _n,
00098 const int _un);
00099
00100
00101
00102
00103 int db_postgres_fetch_result(const db_con_t* _h, db_res_t** _r, const int nrows);
00104
00105
00106
00107
00108
00109
00110 int db_postgres_use_table(db_con_t* _h, const str* _t);
00111
00112
00113 #endif