jrgemignani commented on code in PR #1015:
URL: https://github.com/apache/age/pull/1015#discussion_r1254731295


##########
src/backend/utils/adt/agtype.c:
##########
@@ -4661,56 +4670,57 @@ Datum column_get_datum(TupleDesc tupdesc, HeapTuple 
tuple, int column,
  * function returns a pointer to a duplicated string that needs to be freed
  * when you are finished using it.
  */
-static char *get_label_name(const char *graph_name, int64 graphid)
+static char *get_label_name(const char *graph_name, int64 label_id)
 {
     ScanKeyData scan_keys[2];
     Relation ag_label;
     SysScanDesc scan_desc;
     HeapTuple tuple;
     TupleDesc tupdesc;
     char *result = NULL;
+    bool column_is_null;
 
-    Oid graphoid = get_graph_oid(graph_name);
+    Oid graph_id = get_graph_oid(graph_name);
 
     /* scankey for first match in ag_label, column 2, graphoid, BTEQ, OidEQ */
     ScanKeyInit(&scan_keys[0], Anum_ag_label_graph, BTEqualStrategyNumber,
-                F_OIDEQ, ObjectIdGetDatum(graphoid));
+                F_OIDEQ, ObjectIdGetDatum(graph_id));
     /* scankey for second match in ag_label, column 3, label id, BTEQ, Int4EQ 
*/
     ScanKeyInit(&scan_keys[1], Anum_ag_label_id, BTEqualStrategyNumber,
-                F_INT4EQ, Int32GetDatum(get_graphid_label_id(graphid)));
+                F_INT42EQ, Int32GetDatum(get_graphid_label_id(label_id)));

Review Comment:
   Yeah. I just checked the difference between the two. One is 4:4 the other is 
4:2, lhs:rhs byte size. I also checked the values being compared and both are 4 
bytes. So, I don't know why it is 42 in PG12 and 4 in PG11. Likely a typo. I 
will correct it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to