Go to the SVN repository for this file.
11 main(
intargc,
char**argv)
22printf(
"Starting %s\n", argv[0]);
29printf(
"About to logon as \"%s\"\n",
USER);
36printf(
"About to open \"%s\"\n",
SERVER);
40fprintf(stderr,
"Unable to connect to %s\n",
SERVER);
45printf(
"Using database \"%s\"\n",
DATABASE);
55fprintf(stderr,
"error: expected a result set, none returned.\n");
60fprintf(stderr,
"error: unexpected error from dbcanquery.\n");
65fprintf(stderr,
"error: expected a result set, none returned.\n");
70fprintf(stderr,
"Had problem with bind\n");
75fprintf(stderr,
"Failed. Expected a row\n");
80fprintf(stderr,
"Failed. Expected row data to be 2, was %d\n",
data);
85fprintf(stderr,
"Was expecting no more rows\n");
int main(int argc, char **argv)
CS_RETCODE read_login_info(void)
int syb_err_handler(DBPROCESS *dbproc, int severity, int dberr, int oserr, char *dberrstr, char *oserrstr)
RETCODE sql_cmd(DBPROCESS *dbproc)
int syb_msg_handler(DBPROCESS *dbproc, DBINT msgno, int msgstate, int severity, char *msgtext, char *srvname, char *procname, int line)
void set_malloc_options(void)
static DBPROCESS * dbproc
#define DBSETLPWD(x, y)
Set the password in the login packet.
#define DBSETLAPP(x, y)
Set the (client) application name in the login packet.
#define DBSETLUSER(x, y)
Set the username in the login packet.
LOGINREC * dblogin(void)
Allocate a LOGINREC structure.
RETCODE dbresults(DBPROCESS *dbproc)
Set up query results.
RETCODE dbcanquery(DBPROCESS *dbproc)
Cancel the query currently being retrieved, discarding all pending rows.
RETCODE dbinit(void)
Initialize db-lib.
RETCODE dbuse(DBPROCESS *dbproc, const char *name)
Change current database.
RETCODE dbbind(DBPROCESS *dbproc, int column, int vartype, DBINT varlen, BYTE *varaddr)
Tie a host variable to a resultset column.
RETCODE dbsqlexec(DBPROCESS *dbproc)
send the SQL command to the server and wait for an answer.
EHANDLEFUNC dberrhandle(EHANDLEFUNC handler)
Set an error handler, for messages from db-lib.
void dbloginfree(LOGINREC *login)
free the LOGINREC
void dbexit()
Close server connections and free all related structures.
MHANDLEFUNC dbmsghandle(MHANDLEFUNC handler)
Set a message handler, for messages from the server.
void dbclose(DBPROCESS *dbproc)
Close a connection to the server and free associated resources.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4