• Publicity: Public Only All

sql-statement-procs.tcl

Procs for manipulating SQL statements

Location:
packages/acs-tcl/tcl/sql-statement-procs.tcl
Author:
lars@pinds.com, May 2000
CVS Identification:
$Id: sql-statement-procs.tcl,v 1.5.2.4 2022/07/13 09:44:04 antoniop Exp $ How to use this: You simply call ad_sql_append any number of times, then ad_sql_get to feed to the database. What you gain from using these two procs is that the parts of the SQL statement will always be output in the right sequence. How this works: We represent a SQL statement as a Tcl array of the form stmt(select) { t1.column1 t2.column2 t2.column3 ... } join by , stmt(from) { { table1 t1} {table2 t2} } join by , stmt(where) { condition1 condition2 } join by and stmt(groupby) { groupcol1 groupcol2 } join by , stmt(orderby) { {ordercol1 asc} {ordercol2 desc}} join by , This is unused and untested code.

Procedures in this file

Detailed information

[ show source ]