v10-0010-adapt-property-graph-to-more-intuitive-titles.patch

application/octet-stream

Filename: v10-0010-adapt-property-graph-to-more-intuitive-titles.patch
Type: application/octet-stream
Part: 2
Message: Re: SQL Property Graph Queries (SQL/PGQ)

Patch

Same data as JSON: GET /api/v1/attachments/:id/patch the parsed metadata as JSON — format, series position, per-file stats; never the diff bytes. API reference →
Format: format-patch
Series: patch v10-0010
Subject: adapt property graph to more-intuitive titles
File+
src/bin/psql/describe.c 6 0
src/test/regress/expected/create_property_graph.out 1 1
From 2905fb972caf35260e23bfefc1c356279b287c8d Mon Sep 17 00:00:00 2001
From: Junwang Zhao <zhjwpku@gmail.com>
Date: Fri, 7 Feb 2025 14:57:52 +0000
Subject: [PATCH v10 10/12] adapt property graph to more-intuitive titles

---
 src/bin/psql/describe.c                             | 6 ++++++
 src/test/regress/expected/create_property_graph.out | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/bin/psql/describe.c b/src/bin/psql/describe.c
index 124a749aed8..5751a228118 100644
--- a/src/bin/psql/describe.c
+++ b/src/bin/psql/describe.c
@@ -4257,6 +4257,9 @@ listTables(const char *tabtypes, const char *pattern, bool verbose, bool showSys
 			else if (showForeign)
 				pg_log_error("Did not find any foreign tables named \"%s\".",
 							 pattern);
+			else if (showPropGraphs)
+				pg_log_error("Did not find any property graphs named \"%s\".",
+							 pattern);
 			else				/* should not get here */
 				pg_log_error_internal("Did not find any ??? named \"%s\".",
 									  pattern);
@@ -4277,6 +4280,8 @@ listTables(const char *tabtypes, const char *pattern, bool verbose, bool showSys
 				pg_log_error("Did not find any sequences.");
 			else if (showForeign)
 				pg_log_error("Did not find any foreign tables.");
+			else if (showPropGraphs)
+				pg_log_error("Did not find any property graphs.");
 			else				/* should not get here */
 				pg_log_error_internal("Did not find any ??? relations.");
 		}
@@ -4291,6 +4296,7 @@ listTables(const char *tabtypes, const char *pattern, bool verbose, bool showSys
 			(showMatViews) ? _("List of materialized views") :
 			(showSeq) ? _("List of sequences") :
 			(showForeign) ? _("List of foreign tables") :
+			(showPropGraphs) ? _("List of property graphs") :
 			"List of ???";		/* should not get here */
 		myopt.translate_header = true;
 		myopt.translate_columns = translate_columns;
diff --git a/src/test/regress/expected/create_property_graph.out b/src/test/regress/expected/create_property_graph.out
index 824695358f8..41a89a2708f 100644
--- a/src/test/regress/expected/create_property_graph.out
+++ b/src/test/regress/expected/create_property_graph.out
@@ -645,7 +645,7 @@ SELECT pg_get_propgraphdef('pg_type'::regclass);  -- error
 ERROR:  "pg_type" is not a property graph
 \a\t
 \dG g1
-                             List of relations
+                          List of property graphs
            Schema            | Name |      Type      |        Owner        
 -----------------------------+------+----------------+---------------------
  create_property_graph_tests | g1   | property graph | regress_graph_user1
-- 
2.39.5