~ubuntu-branches/ubuntu/warty/ncbi-tools6/warty

« back to all changes in this revision

Viewing changes to network/medarch/server/medschema.h

  • Committer: Bazaar Package Importer
  • Author(s): Aaron M. Ucko
  • Date: 2002-04-04 22:13:09 UTC
  • Revision ID: james.westby@ubuntu.com-20020404221309-vfze028rfnlrldct
Tags: upstream-6.1.20011220a
ImportĀ upstreamĀ versionĀ 6.1.20011220a

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
*
 
3
*
 
4
* RCS Modification History:
 
5
* $Log: medschema.h,v $
 
6
* Revision 6.0  1997/08/25 18:36:35  madden
 
7
* Revision changed to 6.0
 
8
*
 
9
* Revision 1.2  1995/05/17 17:55:15  epstein
 
10
* add RCS log revision history
 
11
*
 
12
*/
 
13
 
 
14
#ifndef DEFS_MODULE_MEDSCHEMA_H
 
15
 
 
16
#include        "sybase.h"
 
17
 
 
18
#define MAX_STRING_SIZE         255
 
19
#define MAX_BINARY_SIZE         255
 
20
#define MAX_ABSTRACT_SIZE       (6*1024)
 
21
#define MAX_AUTHOR_COUNT        150
 
22
#define MAX_MESH_COUNT          40
 
23
#define MAX_QUALIFIER_COUNT     10
 
24
#define MAX_SUBSTANCE_COUNT     50
 
25
#define MAX_XREF_COUNT          50
 
26
#define MAX_IDNUM_COUNT         20
 
27
#define MAX_GENESYM_COUNT       25
 
28
 
 
29
#define DbString(Name,Size) DBCHAR      Name[Size+1]
 
30
#define DbBinary(Name,Size) DBBINARY    Name[Size+1]
 
31
 
 
32
/* Define the maximum character column size */
 
33
 
 
34
typedef DBCHAR          MaxString[SRV_MAXCHAR+1];
 
35
typedef unsigned char   MaxBinary[SRV_MAXCHAR];
 
36
 
 
37
/* Define the sizes of various fields in various tables */
 
38
 
 
39
/* Table Article */
 
40
 
 
41
#define DBSIZE_Article_pages    40
 
42
#define DBSIZE_Article_title    245
 
43
#define DBSIZE_Article_title1   255
 
44
#define DBSIZE_Article_vtitle   245
 
45
#define DBSIZE_Article_vtitle1  255
 
46
#define DBSIZE_Article_address  255
 
47
 
 
48
#define DBSIZE_Abstract_abstract 255
 
49
 
 
50
#define DBSIZE_CrossReference_accession 30
 
51
 
 
52
#define DBSIZE_Databases_database_name  30
 
53
 
 
54
#define DBSIZE_Issue_volume     25
 
55
#define DBSIZE_Issue_issue      25
 
56
#define DBSIZE_Issue_pubdate    30
 
57
#define DBSIZE_Issue_special_list 1
 
58
 
 
59
#define DBSIZE_Language_language_code   3
 
60
#define DBSIZE_Mesh_heading     128
 
61
#define DBSIZE_Mesh_main_point  1
 
62
 
 
63
#define DBSIZE_Journal_med_abbr 128
 
64
 
 
65
#define DBSIZE_Name_name        128
 
66
 
 
67
#define DBSIZE_Subheading_code  2
 
68
#define DBSIZE_Subheading_main_point 1
 
69
#define DBSIZE_Subheading_name  30
 
70
#define DBSIZE_Subheading_description   60
 
71
 
 
72
#define DBSIZE_Substance_number 30
 
73
#define DBSIZE_Substance_name   250
 
74
 
 
75
#define DBSIZE_ResearchSupport_id       255
 
76
 
 
77
#define DBSIZE_GeneSymbol_symbol        72
 
78
 
 
79
#if defined(__STDC__)
 
80
        /* NOTE: ANSI-C has a portable concatenation mechanism, unlike the
 
81
           non ANSI-C compilers which use the code below. */
 
82
 
 
83
#define DbNColumn(Table,Column,Name) \
 
84
        DBCHAR Name[DBSIZE_ ## Table ## _ ## Column + 1]
 
85
#define DbTitle(Title) \
 
86
    DBCHAR Title[DBSIZE_Article_ ## Title + DBSIZE_Article_ ## Title ## 1 + 1]
 
87
 
 
88
#else
 
89
        /* WARNING- The method used for concatenation used in the macros
 
90
           below is not portable.  This method works for Sun compilers.
 
91
           Your compiler may use a different method.  If so, substitute
 
92
           your concatenation operator for the slash,star,star,slash
 
93
           below.  If your compiler doesn't support concatenation, you'll
 
94
           have to recode the types by hand. */
 
95
 
 
96
#define DbNColumn(Table,Column,Name) \
 
97
        DBCHAR Name[DBSIZE_/**/Table/**/_/**/Column + 1]
 
98
#define DbTitle(Title) \
 
99
    DBCHAR Title[DBSIZE_Article_/**/Title + DBSIZE_Article_/**/Title/**/1 + 1]
 
100
 
 
101
#endif
 
102
#define DbColumn(Table,Column) DbNColumn(Table,Column,Column)
 
103
 
 
104
#endif  /* DEFS_MODULE_MEDSCHEMA_H */