@@ -10,10 +10,10 @@ var (
1010 ErrConnectionRequired = errors .New (
1111 "database connection failed. Please check POSTGRES_URL or DATABASE_URL environment variable" ,
1212 )
13- ErrSchemaRequired = errors .New ("schema name is required" )
14- ErrTableRequired = errors .New ("table name is required" )
15- ErrQueryRequired = errors .New ("query is required" )
16- ErrInvalidQuery = errors .New ("only SELECT and WITH queries are allowed" )
13+ ErrSchemaRequired = errors .New ("schema name is required" )
14+ ErrTableRequired = errors .New ("table name is required" )
15+ ErrQueryRequired = errors .New ("query is required" )
16+ ErrInvalidQuery = errors .New ("only SELECT and WITH queries are allowed" )
1717 ErrNoConnectionString = errors .New (
1818 "no database connection string found in POSTGRES_URL or DATABASE_URL environment variables" ,
1919 )
@@ -58,20 +58,20 @@ type ColumnInfo struct {
5858
5959// IndexInfo represents index metadata.
6060type IndexInfo struct {
61- Name string `json:"name"`
62- Table string `json:"table"`
63- Columns []string `json:"columns"`
64- IsUnique bool `json:"is_unique"`
65- IsPrimary bool `json:"is_primary"`
66- IndexType string `json:"index_type"`
67- Size string `json:"size,omitempty"`
61+ Name string `json:"name"`
62+ Table string `json:"table"`
63+ Columns []string `json:"columns"`
64+ IsUnique bool `json:"is_unique"`
65+ IsPrimary bool `json:"is_primary"`
66+ IndexType string `json:"index_type"`
67+ Size string `json:"size,omitempty"`
6868}
6969
7070// QueryResult represents the result of a query execution.
7171type QueryResult struct {
72- Columns []string `json:"columns"`
73- Rows [][]interface {} `json:"rows"`
74- RowCount int `json:"row_count"`
72+ Columns []string `json:"columns"`
73+ Rows [][]interface {} `json:"rows"`
74+ RowCount int `json:"row_count"`
7575}
7676
7777// ConnectionManager handles database connection operations.
@@ -109,4 +109,4 @@ type PostgreSQLClient interface {
109109 DatabaseExplorer
110110 TableExplorer
111111 QueryExecutor
112- }
112+ }
0 commit comments