Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
postgres-lambda-diff
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakob Huber
postgres-lambda-diff
Commits
d79bb2fd
Commit
d79bb2fd
authored
28 years ago
by
Marc G. Fournier
Browse files
Options
Downloads
Patches
Plain Diff
quick doc cleanup for libpgtcl from D'Arcy
parent
02638701
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
doc/libpgtcl.doc
+20
-1
20 additions, 1 deletion
doc/libpgtcl.doc
with
20 additions
and
1 deletion
doc/libpgtcl.doc
+
20
−
1
View file @
d79bb2fd
...
@@ -17,6 +17,7 @@ The pgtcl package provides the following commands.
...
@@ -17,6 +17,7 @@ The pgtcl package provides the following commands.
pg_connect - opens a connection to the backend server
pg_connect - opens a connection to the backend server
pg_disconnect - closes a connection
pg_disconnect - closes a connection
pg_exec - send a query to the backend
pg_exec - send a query to the backend
pg_select - loop over the result of a select statement
pg_result - manipulate the results of a query
pg_result - manipulate the results of a query
pg_lo_creat - create a large object
pg_lo_creat - create a large object
...
@@ -54,7 +55,25 @@ The pgtcl package provides the following commands.
...
@@ -54,7 +55,25 @@ The pgtcl package provides the following commands.
the return result is either an error message or a handle for a query
the return result is either an error message or a handle for a query
result. Handles start with the prefix "pgp"
result. Handles start with the prefix "pgp"
4) pg_result: get information about a query result
4) pg_select: loop over the result of a select statement
syntax:
pg_select connection query var proc
The query must be a select statement. Anything else returns an error.
The var variable is an array name used in the loop. It is filled
out with the result of the query for each tuple using the field
names as the associative indeces. Proc is the procedure that is
run for each tuple found.
example: (DB is set to database name)
set conn [pg_connect $DB]
pg_select $conn "SELECT * from table" array {
puts [format "%5d %s" array(control) array(name)]
}
pg_disconnect $conn
5) pg_result: get information about a query result
syntax:
syntax:
pg_result result ?option?
pg_result result ?option?
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment