aboutsummaryrefslogtreecommitdiff
path: root/pkg/tbtables/tbcfnd1.x
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2015-07-08 20:46:52 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2015-07-08 20:46:52 -0400
commitfa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 (patch)
treebdda434976bc09c864f2e4fa6f16ba1952b1e555 /pkg/tbtables/tbcfnd1.x
downloadiraf-linux-fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4.tar.gz
Initial commit
Diffstat (limited to 'pkg/tbtables/tbcfnd1.x')
-rw-r--r--pkg/tbtables/tbcfnd1.x25
1 files changed, 25 insertions, 0 deletions
diff --git a/pkg/tbtables/tbcfnd1.x b/pkg/tbtables/tbcfnd1.x
new file mode 100644
index 00000000..db789c0d
--- /dev/null
+++ b/pkg/tbtables/tbcfnd1.x
@@ -0,0 +1,25 @@
+include <tbset.h>
+
+# tbcfnd1 -- find a column
+# Find a column in a table. This just calls tbcfnd.
+# If the column is not found in the table, colptr will be set to NULL.
+#
+# Phil Hodge, 21-Aug-1995 Subroutine created.
+
+procedure tbcfnd1 (tp, colname, colptr)
+
+pointer tp # i: pointer to table descriptor
+char colname[SZ_COLNAME] # i: name of column
+pointer colptr # o: pointer to column, or NULL
+#--
+pointer cp[1] # pointer to column, or NULL
+char cname[SZ_COLNAME,1] # name of column
+errchk tbcfnd
+
+begin
+ call strcpy (colname[1], cname[1,1], SZ_COLNAME)
+
+ call tbcfnd (tp, cname, cp, 1)
+
+ colptr = cp[1]
+end