fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [16435]


From: nelson . guerra
Subject: [Fmsystem-commits] [16435]
Date: Thu, 16 Mar 2017 00:43:30 -0400 (EDT)

Revision: 16435
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=16435
Author:   nelson224
Date:     2017-03-16 00:43:30 -0400 (Thu, 16 Mar 2017)
Log Message:
-----------


Modified Paths:
--------------
    branches/dev-syncromind-2/property/inc/class.soreport.inc.php

Modified: branches/dev-syncromind-2/property/inc/class.soreport.inc.php
===================================================================
--- branches/dev-syncromind-2/property/inc/class.soreport.inc.php       
2017-03-14 14:07:16 UTC (rev 16434)
+++ branches/dev-syncromind-2/property/inc/class.soreport.inc.php       
2017-03-16 04:43:30 UTC (rev 16435)
@@ -52,7 +52,6 @@
                                        AND table_type = 'VIEW'";
        
                        $this->db->query($sql, __LINE__, __FILE__);
-                       $this->total_records = $this->db->num_rows();
 
                        $values = array();
 
@@ -69,4 +68,28 @@
                        return $values;
                }
                
+               public function get_columns($table)
+               {
+                       $sql = "SELECT column_name, data_type
+                               FROM   information_schema.columns
+                               WHERE  table_name = '".$table."'
+                               ORDER  BY ordinal_position";
+       
+                       $this->db->query($sql, __LINE__, __FILE__);
+
+                       $values = array();
+
+                       $this->db->query($sql, __LINE__, __FILE__);
+
+                       while ($this->db->next_record())
+                       {
+                               $values[] = array
+                                       (
+                                       'name' => $this->db->f('column_name'),
+                                       'type' => $this->db->f('data_type')
+                               );
+                       }
+                       
+                       return $values;
+               }
        }
\ No newline at end of file




reply via email to

[Prev in Thread] Current Thread [Next in Thread]