Difference between revisions of "Conf/Examples/DatabseExample"

From AOLserver Wiki
Jump to navigation Jump to search
(Created page with ' <html> <head><title>Testing of ADP</title></head> <body> kjhkjhk <% set pool "postgres_pool" set sql "select * from users" set db [ns_db gethandle $pool] …')
 
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
  <html>
+
[[Conf/Examples/DatabseConfig| part of AOL Database Configuration with PostgreSQL]]
     <head><title>Testing of ADP</title></head>
+
 +
<html>
 +
     <head><title>Testing of Database connection</title></head>
 
   <body>   
 
   <body>   
   kjhkjhk
+
   A simple tcl script example of Database Configuration
 
   <%  
 
   <%  
 
   set pool "postgres_pool"
 
   set pool "postgres_pool"
Line 13: Line 15:
 
   ns_db releasehandle $db
 
   ns_db releasehandle $db
 
   %>
 
   %>
 
 
   </body>
 
   </body>
 
   </html>
 
   </html>

Latest revision as of 13:54, 11 January 2012

part of AOL Database Configuration with PostgreSQL

<html>
   <head><title>Testing of Database connection</title></head>
 <body>  
 A simple tcl script example of Database Configuration
 <% 
  set pool "postgres_pool"
  set sql "select * from users"
  set db [ns_db gethandle $pool]
  set row [ns_db select $db $sql]
  while {[ns_db getrow $db $row]} {
   ns_adp_puts "row: [ns_set array $row]"
  }	
  ns_db releasehandle $db
 %>
 </body>
 </html>