FileRelationshipList.xml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
  4. <sect1 id="FileRelationshipList">
  5. <title>FileRelationshipList</title>
  6. <para><emphasis role="bold">STD.File.FileRelationshipList<indexterm>
  7. <primary>STD.File.FileRelationshipList</primary>
  8. </indexterm><indexterm>
  9. <primary>File.FileRelationshipList</primary>
  10. </indexterm><indexterm>
  11. <primary>FileRelationshipList</primary>
  12. </indexterm>(</emphasis> <emphasis> primary, secondary</emphasis>
  13. <emphasis> </emphasis> <emphasis role="bold">[</emphasis> <emphasis>,
  14. primaryfields </emphasis> <emphasis role="bold">]</emphasis> <emphasis>
  15. </emphasis> <emphasis role="bold">[</emphasis> <emphasis>, secondaryfields
  16. </emphasis> <emphasis role="bold">]</emphasis> <emphasis role="bold">
  17. [</emphasis> <emphasis>,</emphasis> <emphasis role="bold"> </emphasis>
  18. <emphasis>relationship </emphasis> <emphasis
  19. role="bold">]);</emphasis></para>
  20. <informaltable colsep="1" frame="all" rowsep="1">
  21. <tgroup cols="2">
  22. <colspec colwidth="80.50pt" />
  23. <colspec />
  24. <tbody>
  25. <row>
  26. <entry><emphasis>primary</emphasis></entry>
  27. <entry>A null-terminated string containing the logical filename of
  28. the primary file.</entry>
  29. </row>
  30. <row>
  31. <entry><emphasis>secondary</emphasis></entry>
  32. <entry>A null-terminated string containing the logical filename of
  33. the secondary file.</entry>
  34. </row>
  35. <row>
  36. <entry><emphasis>primaryfields</emphasis></entry>
  37. <entry>A null-terminated string containing the name of the primary
  38. key field for the <emphasis>primary</emphasis> file. The value
  39. “__fileposition__” indicates the <emphasis>secondary</emphasis> is
  40. an INDEX that must use FETCH to access non-keyed fields. If omitted,
  41. the default is an empty string.</entry>
  42. </row>
  43. <row>
  44. <entry><emphasis>secondaryfields</emphasis></entry>
  45. <entry>A null-terminated string containing the name of the foreign
  46. key field relating to the <emphasis>primary</emphasis> file. If
  47. omitted, the default is an empty string.</entry>
  48. </row>
  49. <row>
  50. <entry><emphasis>relationship</emphasis></entry>
  51. <entry>A null-terminated string containing either “link” or “view”
  52. indicating the type of relationship between the
  53. <emphasis>primary</emphasis> and <emphasis>secondary</emphasis>
  54. files. If omitted, the default is “link.”</entry>
  55. </row>
  56. <row>
  57. <entry>Return:</entry>
  58. <entry>FileRelationshipList returns a dataset in the
  59. FsFileRelationshipRecord format.</entry>
  60. </row>
  61. </tbody>
  62. </tgroup>
  63. </informaltable>
  64. <para>The <emphasis role="bold">FileRelationshipList</emphasis> function
  65. returns a list file relationships between the <emphasis>primary</emphasis>
  66. and <emphasis>secondary</emphasis> files. The return records are structured
  67. in the FsFileRelationshipRecord format:</para>
  68. <programlisting>EXPORT FsFileRelationshipRecord := RECORD
  69. STRING primaryfile {MAXLENGTH(1023)};
  70. STRING secondaryfile {MAXLENGTH(1023)};
  71. STRING primaryflds {MAXLENGTH(1023)};
  72. STRING secondaryflds {MAXLENGTH(1023)};
  73. STRING kind {MAXLENGTH(16)};
  74. STRING cardinality {MAXLENGTH(16)};
  75. BOOLEAN payload;
  76. STRING description {MAXLENGTH(1023)};
  77. END;</programlisting>
  78. <para>Example:</para>
  79. <programlisting format="linespecific">OUTPUT(STD.File.FileRelationshipList('names', 'inquiries'));
  80. </programlisting>
  81. <para>See Also: <link
  82. linkend="AddFileRelationship">AddFileRelationship</link></para>
  83. </sect1>