Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc773ec6

Browse files
committed
Fix map_sql_table_to_xmlschema() with dropped attributes.
also backpatched to 8.3
1 parenta1fd650 commitc773ec6

File tree

1 file changed

+5
-1
lines changed
  • src/backend/utils/adt

1 file changed

+5
-1
lines changed

‎src/backend/utils/adt/xml.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $PostgreSQL: pgsql/src/backend/utils/adt/xml.c,v 1.88 2009/05/13 20:27:17 tgl Exp $
10+
* $PostgreSQL: pgsql/src/backend/utils/adt/xml.c,v 1.89 2009/06/08 21:32:33 petere Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -2627,12 +2627,16 @@ map_sql_table_to_xmlschema(TupleDesc tupdesc, Oid relid, bool nulls,
26272627
rowtypename);
26282628

26292629
for (i=0;i<tupdesc->natts;i++)
2630+
{
2631+
if (tupdesc->attrs[i]->attisdropped)
2632+
continue;
26302633
appendStringInfo(&result,
26312634
" <xsd:element name=\"%s\" type=\"%s\"%s></xsd:element>\n",
26322635
map_sql_identifier_to_xml_name(NameStr(tupdesc->attrs[i]->attname),
26332636
true, false),
26342637
map_sql_type_to_xml_name(tupdesc->attrs[i]->atttypid,-1),
26352638
nulls ?" nillable=\"true\"" :" minOccurs=\"0\"");
2639+
}
26362640

26372641
appendStringInfoString(&result,
26382642
" </xsd:sequence>\n"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp