summaryrefslogtreecommitdiff
path: root/docs/doxygen/latex/xbsql_8h_source.tex
diff options
context:
space:
mode:
Diffstat (limited to 'docs/doxygen/latex/xbsql_8h_source.tex')
-rw-r--r--docs/doxygen/latex/xbsql_8h_source.tex169
1 files changed, 127 insertions, 42 deletions
diff --git a/docs/doxygen/latex/xbsql_8h_source.tex b/docs/doxygen/latex/xbsql_8h_source.tex
index f42eca3..f52325d 100644
--- a/docs/doxygen/latex/xbsql_8h_source.tex
+++ b/docs/doxygen/latex/xbsql_8h_source.tex
@@ -1,5 +1,5 @@
\hypertarget{xbsql_8h_source}{}\doxysection{xbsql.\+h}
-\label{xbsql_8h_source}\index{/mnt/1Tdata/xbase/xbase64-\/4.0.3/src/include/xbsql.h@{/mnt/1Tdata/xbase/xbase64-\/4.0.3/src/include/xbsql.h}}
+\label{xbsql_8h_source}\index{/mnt/1Tdata/xbase/xbase64-\/4.1.0/src/include/xbsql.h@{/mnt/1Tdata/xbase/xbase64-\/4.1.0/src/include/xbsql.h}}
\mbox{\hyperlink{xbsql_8h}{Go to the documentation of this file.}}
\begin{DoxyCode}{0}
\DoxyCodeLine{1 \textcolor{comment}{/* xbsql.h}}
@@ -33,50 +33,135 @@
\DoxyCodeLine{29 \textcolor{keyword}{namespace }\mbox{\hyperlink{namespacexb}{xb}}\{}
\DoxyCodeLine{30 }
\DoxyCodeLine{31 }
-\DoxyCodeLine{32 \textcolor{keyword}{class }XBDLLEXPORT xbSql : \textcolor{keyword}{public} xbSsv \{}
-\DoxyCodeLine{33 \textcolor{keyword}{public}:}
-\DoxyCodeLine{34 \textcolor{comment}{// xbSql();}}
-\DoxyCodeLine{35 xbSql( \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *x );}
-\DoxyCodeLine{36 \string~xbSql();}
-\DoxyCodeLine{37 }
-\DoxyCodeLine{38 xbInt16 ExecuteNonQuery( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{39 \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *GetXbasePtr() \textcolor{keyword}{const};}
-\DoxyCodeLine{40 }
-\DoxyCodeLine{41 \textcolor{keyword}{protected}:}
-\DoxyCodeLine{42 }
-\DoxyCodeLine{43 \textcolor{keyword}{private}:}
+\DoxyCodeLine{32 \textcolor{keyword}{struct }XBDLLEXPORT xbSqlFld\{}
+\DoxyCodeLine{33 \textcolor{keywordtype}{char} cType; \textcolor{comment}{// F -\/ Database field}}
+\DoxyCodeLine{34 \textcolor{comment}{// L -\/ Literal}}
+\DoxyCodeLine{35 \textcolor{comment}{// E -\/ Expression}}
+\DoxyCodeLine{36 xbInt16 iFldNo; \textcolor{comment}{// Field number if db field}}
+\DoxyCodeLine{37 xbExp * pExp; \textcolor{comment}{// If cType=E, pointer to parsed expression}}
+\DoxyCodeLine{38 xbString sFldAlias; \textcolor{comment}{// Alias name for query display}}
+\DoxyCodeLine{39 xbSqlFld * Next; \textcolor{comment}{// Next field in list}}
+\DoxyCodeLine{40 \};}
+\DoxyCodeLine{41 }
+\DoxyCodeLine{42 \textcolor{keyword}{class }xbStmt;}
+\DoxyCodeLine{43 }
\DoxyCodeLine{44 }
-\DoxyCodeLine{45 xbInt16 SqlAlterTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{45 \textcolor{keyword}{struct }XBDLLEXPORT xbTblJoin \{ \textcolor{comment}{// structure for defining joined tables in the query}}
\DoxyCodeLine{46 }
-\DoxyCodeLine{47 xbInt16 SqlCreateTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{48 }
-\DoxyCodeLine{49 xbInt16 SqlDelete( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{50 }
-\DoxyCodeLine{51 xbInt16 SqlDropTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{52 }
-\DoxyCodeLine{53 }
-\DoxyCodeLine{54 \textcolor{preprocessor}{ \#ifdef XB\_INDEX\_SUPPORT}}
-\DoxyCodeLine{55 xbInt16 SqlCreateIndex( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{56 xbInt16 SqlDropIndex( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{57 \textcolor{preprocessor}{ \#endif }\textcolor{comment}{// XB\_INDEX\_SUPPORT}}
+\DoxyCodeLine{47 xbString sTableName;}
+\DoxyCodeLine{48 xbString sAlias;}
+\DoxyCodeLine{49 xbString sJoinExp; \textcolor{comment}{// table join expression}}
+\DoxyCodeLine{50 \mbox{\hyperlink{namespacexb_ab2eae4b4732466698a7fdd89d77ba53b}{xbDbf}} *pDbf; \textcolor{comment}{// pointer the the dbf structure for this table}}
+\DoxyCodeLine{51 xbTag *pTag; \textcolor{comment}{// pointer to relevant tag for this table, null for record order}}
+\DoxyCodeLine{52 xbExp *pLinkExp; \textcolor{comment}{// pointer to parsed linkage expression}}
+\DoxyCodeLine{53 \textcolor{keywordtype}{char} cJoinType; \textcolor{comment}{// M -\/ Master}}
+\DoxyCodeLine{54 \textcolor{comment}{// L -\/ Left or Full Left}}
+\DoxyCodeLine{55 \textcolor{comment}{// R -\/ Right or Full Right}}
+\DoxyCodeLine{56 \textcolor{comment}{// I -\/ Inner}}
+\DoxyCodeLine{57 \textcolor{comment}{// O -\/ Outer or Full Outer Outer}}
\DoxyCodeLine{58 }
-\DoxyCodeLine{59 \textcolor{comment}{// xbInt16 SqlCreateView( const xbString \&sCmdLine );}}
-\DoxyCodeLine{60 \textcolor{comment}{// xbInt16 SqlDropView( const xbString \&sCmdLine );}}
-\DoxyCodeLine{61 \textcolor{comment}{// xbInt16 SqlUpdate( const xbString \&sCmdLine );}}
-\DoxyCodeLine{62 \textcolor{comment}{// xbInt16 SqlSelect( const xbString \&sCmdLine );}}
-\DoxyCodeLine{63 }
-\DoxyCodeLine{64 \textcolor{keywordtype}{void} SqlHelp() \textcolor{keyword}{const};}
-\DoxyCodeLine{65 xbInt16 SqlInsert( \textcolor{keyword}{const} xbString \&sCmLine );}
-\DoxyCodeLine{66 xbInt16 SqlSet( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{67 xbInt16 SqlUse( \textcolor{keyword}{const} xbString \&sCmdLine );}
-\DoxyCodeLine{68 }
-\DoxyCodeLine{69 \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *xbase;}
-\DoxyCodeLine{70 xbUda uda;}
+\DoxyCodeLine{59 xbTblJoin *pMaster; \textcolor{comment}{// pointer to master table, null if this is the primary master}}
+\DoxyCodeLine{60 xbLinkList<xbTblJoin *> llSubList; \textcolor{comment}{// linked list of subordinate tables}}
+\DoxyCodeLine{61 \textcolor{comment}{// xbStmt *pSubQuery; // pointer to sub query}}
+\DoxyCodeLine{62 xbTblJoin *next; \textcolor{comment}{// next tbl}}
+\DoxyCodeLine{63 \};}
+\DoxyCodeLine{64 }
+\DoxyCodeLine{65 }
+\DoxyCodeLine{66 \textcolor{keyword}{class }XBDLLEXPORT xbStmt : \textcolor{keyword}{public} xbSsv\{}
+\DoxyCodeLine{67 }
+\DoxyCodeLine{68 \textcolor{keyword}{public}:}
+\DoxyCodeLine{69 xbStmt( \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *x );}
+\DoxyCodeLine{70 \string~xbStmt();}
\DoxyCodeLine{71 }
-\DoxyCodeLine{72 \};}
-\DoxyCodeLine{73 }
-\DoxyCodeLine{74 \} \textcolor{comment}{/* namespace xb */}}
-\DoxyCodeLine{75 \textcolor{preprocessor}{\#endif }\textcolor{comment}{/* XB\_SQL\_SUPPORT */}\textcolor{preprocessor}{}}
-\DoxyCodeLine{76 \textcolor{preprocessor}{\#endif }\textcolor{comment}{/* \_\_XB\_XBSQL\_H\_\_ */}\textcolor{preprocessor}{}}
+\DoxyCodeLine{72 \textcolor{preprocessor}{ \#ifdef XB\_DEBUG\_SUPPORT}}
+\DoxyCodeLine{73 xbInt16 DumpStmtInternals();}
+\DoxyCodeLine{74 xbInt16 Test();}
+\DoxyCodeLine{75 \textcolor{preprocessor}{ \#endif}}
+\DoxyCodeLine{76 }
+\DoxyCodeLine{77 xbInt16 ExecuteQuery( \textcolor{keyword}{const} xbString \&sCmdLine ); }
+\DoxyCodeLine{78 }
+\DoxyCodeLine{79 \textcolor{comment}{// xbInt16 FetchFirst();}}
+\DoxyCodeLine{80 \textcolor{comment}{// xbInt16 FetchNext();}}
+\DoxyCodeLine{81 \textcolor{comment}{// xbInt16 FetchPrev();}}
+\DoxyCodeLine{82 \textcolor{comment}{// xbInt16 FetchLast();}}
+\DoxyCodeLine{83 \textcolor{comment}{// xbString \&GetField( const xbString sFldName );}}
+\DoxyCodeLine{84 }
+\DoxyCodeLine{85 \textcolor{keyword}{protected}:}
+\DoxyCodeLine{86 }
+\DoxyCodeLine{87 \textcolor{keyword}{private}:}
+\DoxyCodeLine{88 }
+\DoxyCodeLine{89 xbInt16 AddQryTbl( \textcolor{keyword}{const} xbString \&sTable, \textcolor{keyword}{const} xbString \&sAlias, \textcolor{keyword}{const} xbString \&sExpression, \textcolor{keyword}{const} \textcolor{keywordtype}{char} cJoinType );}
+\DoxyCodeLine{90 xbInt16 CvtSqlExp2DbaseExp( \textcolor{keyword}{const} xbString \&sExpIn, xbString \&sExpOut );}
+\DoxyCodeLine{91 xbInt16 GetNextFromSeg( \textcolor{keyword}{const} xbString \&sLineIn, xbString \&sFromSegOut );}
+\DoxyCodeLine{92 xbUInt32 GetNextToken( \textcolor{keyword}{const} xbString \&sCmdLineIn, xbString \&sTokenOut, xbUInt32 ulStartPos );}
+\DoxyCodeLine{93 xbInt16 GetParenCnt( \textcolor{keyword}{const} xbString \&sToken );}
+\DoxyCodeLine{94 xbInt16 ParseFromStmt( \textcolor{keyword}{const} xbString \&sFromLine );}
+\DoxyCodeLine{95 xbInt16 ParseStmt( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{96 xbInt16 ProcessFromSeg( \textcolor{keyword}{const} xbString \&sFromStmtSeg );}
+\DoxyCodeLine{97 xbInt16 UpdateJoinList( \textcolor{keywordtype}{char} cType, \textcolor{keyword}{const} xbString \&sTableName, \textcolor{keyword}{const} xbString \&sAlias, \textcolor{keyword}{const} xbString \&sExp, \mbox{\hyperlink{namespacexb_ab2eae4b4732466698a7fdd89d77ba53b}{xbDbf}} *d, xbExp *e ); \textcolor{comment}{//, xbTag *t);}}
+\DoxyCodeLine{98 }
+\DoxyCodeLine{99 \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *xbase; \textcolor{comment}{// pointer to xbase structure}}
+\DoxyCodeLine{100 }
+\DoxyCodeLine{101 }
+\DoxyCodeLine{102 xbTblJoin * pTblList;}
+\DoxyCodeLine{103 xbSqlFld *fl; \textcolor{comment}{// field list in sql select statement}}
+\DoxyCodeLine{104 xbString sStmt; \textcolor{comment}{// complete query statment}}
+\DoxyCodeLine{105 xbString sFields; \textcolor{comment}{// list of fields}}
+\DoxyCodeLine{106 xbString sFrom; \textcolor{comment}{// from statment}}
+\DoxyCodeLine{107 xbString sWhere; \textcolor{comment}{// where clause}}
+\DoxyCodeLine{108 xbString sOrderBy; \textcolor{comment}{// sort order}}
+\DoxyCodeLine{109 xbString sGroupBy; \textcolor{comment}{// group by}}
+\DoxyCodeLine{110 xbString sHaving; \textcolor{comment}{// having}}
+\DoxyCodeLine{111 xbUInt32 ulFromPos;}
+\DoxyCodeLine{112 xbUInt32 ulWherePos;}
+\DoxyCodeLine{113 xbUInt32 ulOrderByPos;}
+\DoxyCodeLine{114 xbUInt32 ulGroupByPos;}
+\DoxyCodeLine{115 xbUInt32 ulHavingPos;}
+\DoxyCodeLine{116 }
+\DoxyCodeLine{117 }
+\DoxyCodeLine{118 \};}
+\DoxyCodeLine{119 }
+\DoxyCodeLine{120 }
+\DoxyCodeLine{121 \textcolor{keyword}{class }XBDLLEXPORT xbSql : \textcolor{keyword}{public} xbSsv \{}
+\DoxyCodeLine{122 \textcolor{keyword}{public}:}
+\DoxyCodeLine{123 \textcolor{comment}{// xbSql();}}
+\DoxyCodeLine{124 xbSql( \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *x );}
+\DoxyCodeLine{125 \string~xbSql();}
+\DoxyCodeLine{126 }
+\DoxyCodeLine{127 xbInt16 ExecuteNonQuery( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{128 \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *GetXbasePtr() \textcolor{keyword}{const};}
+\DoxyCodeLine{129 }
+\DoxyCodeLine{130 \textcolor{keyword}{protected}:}
+\DoxyCodeLine{131 }
+\DoxyCodeLine{132 \textcolor{keyword}{private}:}
+\DoxyCodeLine{133 }
+\DoxyCodeLine{134 xbInt16 SqlAlterTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{135 xbInt16 SqlCreateTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{136 xbInt16 SqlDelete( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{137 xbInt16 SqlDropTable( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{138 }
+\DoxyCodeLine{139 \textcolor{preprocessor}{ \#ifdef XB\_INDEX\_SUPPORT}}
+\DoxyCodeLine{140 xbInt16 SqlCreateIndex( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{141 xbInt16 SqlDropIndex( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{142 \textcolor{preprocessor}{ \#endif }\textcolor{comment}{// XB\_INDEX\_SUPPORT}}
+\DoxyCodeLine{143 }
+\DoxyCodeLine{144 \textcolor{comment}{// xbInt16 SqlCreateView( const xbString \&sCmdLine );}}
+\DoxyCodeLine{145 \textcolor{comment}{// xbInt16 SqlDropView( const xbString \&sCmdLine );}}
+\DoxyCodeLine{146 \textcolor{comment}{// xbInt16 SqlUpdate( const xbString \&sCmdLine );}}
+\DoxyCodeLine{147 \textcolor{comment}{// xbInt16 SqlSelect( const xbString \&sCmdLine );}}
+\DoxyCodeLine{148 }
+\DoxyCodeLine{149 \textcolor{keywordtype}{void} SqlHelp() \textcolor{keyword}{const};}
+\DoxyCodeLine{150 xbInt16 SqlInsert( \textcolor{keyword}{const} xbString \&sCmLine );}
+\DoxyCodeLine{151 xbInt16 SqlSet( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{152 xbInt16 SqlUse( \textcolor{keyword}{const} xbString \&sCmdLine );}
+\DoxyCodeLine{153 }
+\DoxyCodeLine{154 \mbox{\hyperlink{namespacexb_a97858ddeb1c4b0100f3edc1a46d3a8b0}{xbXBase}} *xbase;}
+\DoxyCodeLine{155 xbUda uda;}
+\DoxyCodeLine{156 }
+\DoxyCodeLine{157 \};}
+\DoxyCodeLine{158 }
+\DoxyCodeLine{159 \} \textcolor{comment}{/* namespace xb */}}
+\DoxyCodeLine{160 \textcolor{preprocessor}{\#endif }\textcolor{comment}{/* XB\_SQL\_SUPPORT */}\textcolor{preprocessor}{}}
+\DoxyCodeLine{161 \textcolor{preprocessor}{\#endif }\textcolor{comment}{/* \_\_XB\_XBSQL\_H\_\_ */}\textcolor{preprocessor}{}}
\end{DoxyCode}