env2.c File Reference

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ham/hamsterdb.h>

Go to the source code of this file.

Data Structures

struct  customer_t
struct  order_t

Defines

#define MAX_DBS   3
#define DBNAME_CUSTOMER   1
#define DBNAME_ORDER   2
#define DBNAME_C2O   3
#define DBIDX_CUSTOMER   0
#define DBIDX_ORDER   1
#define DBIDX_C2O   2
#define MAX_CUSTOMERS   4
#define MAX_ORDERS   8

Functions

void error (const char *foo, ham_status_t st)
int main (int argc, char **argv)

Define Documentation

#define DBIDX_C2O   2

Definition at line 51 of file env2.c.

Referenced by main(), and run_demo().

#define DBIDX_CUSTOMER   0

Definition at line 49 of file env2.c.

Referenced by main(), and run_demo().

#define DBIDX_ORDER   1

Definition at line 50 of file env2.c.

Referenced by main(), and run_demo().

#define DBNAME_C2O   3

Definition at line 47 of file env2.c.

Referenced by main(), and run_demo().

#define DBNAME_CUSTOMER   1

Definition at line 45 of file env2.c.

#define DBNAME_ORDER   2

Definition at line 46 of file env2.c.

#define MAX_CUSTOMERS   4

Definition at line 53 of file env2.c.

#define MAX_DBS   3

Definition at line 43 of file env2.c.

#define MAX_ORDERS   8

Definition at line 54 of file env2.c.


Function Documentation

void error ( const char *  foo,
ham_status_t  st 
)

Copyright (C) 2005-2008 Christoph Rupp (chris@crupp.de).

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

See files COPYING.* for License information.

Similar to env1, an environment with a customer- and an order-database is created; a third database is created which manages the 1:n relationship between the other two.

Definition at line 26 of file env2.c.

References ham_strerror().

int main ( int  argc,
char **  argv 
)
Generated by  doxygen 1.6.3