DINIT2B7 ;SFISC/MKO-SQLI FILES ;10:51 AM 30 Mar 1999
;;22.0;VA FileMan;;Mar 30, 1999
;Per VHA Directive 10-93-142, this routine should not be modified.
F I=1:2 S X=$T(Q+I) Q:X="" S Y=$E($T(Q+I+1),4,999),X=$E(X,4,999) S:$A(Y)=126 I=I+1,Y=$E(Y,2,999)_$E($T(Q+I+1),5,99) S:$A(Y)=61 Y=$E(Y,2,999) S @X=Y
G ^DINIT2B8
Q Q
;;^DIC(1.5215,0,"GL")
;;=^DMSQ("T",
;;^DIC("B","SQLI_TABLE",1.5215)
;;=
;;^DIC(1.5215,"%D",0)
;;=^^6^6^2970806^^^
;;^DIC(1.5215,"%D",1,0)
;;=Descriptor of a set of table elements: Includes name and file no.
;;^DIC(1.5215,"%D",2,0)
;;=(See SQLI_TABLE_ELEMENTS). Each ^DD(DA) represents a table in a relational
;;^DIC(1.5215,"%D",3,0)
;;=model of FileMan. Further, each index represents a table.
;;^DIC(1.5215,"%D",4,0)
;;=
;;^DIC(1.5215,"%D",5,0)
;;=Each schema contains multiple tables. Each table contains just one primary
;;^DIC(1.5215,"%D",6,0)
;;=key, but multiple columns, foreign keys and indicies.
;;^DD(1.5215,0)
;;=FIELD^^8^9
;;^DD(1.5215,0,"DDA")
;;=N
;;^DD(1.5215,0,"DT")
;;=2960913
;;^DD(1.5215,0,"IX","B",1.5215,.01)
;;=
;;^DD(1.5215,0,"IX","C",1.5215,6)
;;=
;;^DD(1.5215,0,"IX","D",1.5215,8)
;;=
;;^DD(1.5215,0,"IX","E",1.5215,3)
;;=
;;^DD(1.5215,0,"NM","SQLI_TABLE")
;;=
;;^DD(1.5215,0,"PT",1.5212,3)
;;=
;;^DD(1.5215,0,"PT",1.5215,3)
;;=
;;^DD(1.5215,0,"PT",1.5216,2)
;;=
;;^DD(1.5215,0,"VRPK")
;;=DI
;;^DD(1.5215,.01,0)
;;=T_NAME^RF^^0;1^K:$L(X)>30!($L(X)<3)!'($TR(X,"_")?1U.UN) X
;;^DD(1.5215,.01,.1)
;;=Table
;;^DD(1.5215,.01,1,0)
;;=^.1
;;^DD(1.5215,.01,1,1,0)
;;=1.5215^B
;;^DD(1.5215,.01,1,1,1)
;;=S ^DMSQ("T","B",$E(X,1,30),DA)=""
;;^DD(1.5215,.01,1,1,2)
;;=K ^DMSQ("T","B",$E(X,1,30),DA)
;;^DD(1.5215,.01,3)
;;=Answer must be 3-30 characters in length.
;;^DD(1.5215,.01,9)
;;=^
;;^DD(1.5215,.01,21,0)
;;=^^1^1^2960926^
;;^DD(1.5215,.01,21,1,0)
;;=Table name must be a valid SQL identifier, unique by schema
;;^DD(1.5215,.01,"DT")
;;=2960820
;;^DD(1.5215,1,0)
;;=T_SCHEMA^RP1.521^DMSQ("S",^0;2^Q
;;^DD(1.5215,1,.1)
;;=Schema
;;^DD(1.5215,1,9)
;;=^
;;^DD(1.5215,1,21,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,1,21,1,0)
;;=IEN in SQLI_SCHEMA of the schema to which this table belongs.
;;^DD(1.5215,1,"DT")
;;=2960913
;;^DD(1.5215,2,0)
;;=T_COMMENT^F^^0;3^K:$L(X)>70!($L(X)<3) X
;;^DD(1.5215,2,.1)
;;=Description
;;^DD(1.5215,2,3)
;;=Answer must be 3-70 characters in length.
;;^DD(1.5215,2,9)
;;=^
;;^DD(1.5215,2,21,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,2,21,1,0)
;;=A short description of the table
;;^DD(1.5215,2,"DT")
;;=2960913
;;^DD(1.5215,3,0)
;;=T_MASTER_TABLE^P1.5215'^DMSQ("T",^0;4^Q
;;^DD(1.5215,3,.1)
;;=Master Table
;;^DD(1.5215,3,1,0)
;;=^.1
;;^DD(1.5215,3,1,1,0)
;;=1.5215^E
;;^DD(1.5215,3,1,1,1)
;;=S ^DMSQ("T","E",$E(X,1,30),DA)=""
;;^DD(1.5215,3,1,1,2)
;;=K ^DMSQ("T","E",$E(X,1,30),DA)
;;^DD(1.5215,3,1,1,"%D",0)
;;=^^1^1^2960904^
;;^DD(1.5215,3,1,1,"%D",1,0)
;;=Table by master table
;;^DD(1.5215,3,1,1,"DT")
;;=2960904
;;^DD(1.5215,3,3)
;;=Enter only if this table is an index
;;^DD(1.5215,3,9)
;;=^
;;^DD(1.5215,3,21,0)
;;=^^1^1^2960926^^^
;;^DD(1.5215,3,21,1,0)
;;=The table of which this table is an index. (Only index tables)
;;^DD(1.5215,3,23,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,3,23,1,0)
;;=In SQL, and in the relational model, an index is just a table.
;;^DD(1.5215,3,"DT")
;;=2960913
;;^DD(1.5215,4,0)
;;=T_VERSION_FM^NJ9,0^^0;5^K:+X'=X!(X>999999999)!(X<1)!(X?.E1"."1N.N) X
;;^DD(1.5215,4,.1)
;;=Version
;;^DD(1.5215,4,3)
;;=Type a Number between 1 and 999999999, 0 Decimal Digits
;;^DD(1.5215,4,9)
;;=^
;;^DD(1.5215,4,21,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,4,21,1,0)
;;=The version number is updated by FileMan when ^DD or ^DIC changes.
;;^DD(1.5215,4,"DT")
;;=2960926
;;^DD(1.5215,5,0)
;;=T_ROW_COUNT^NJ9,0^^0;6^K:+X'=X!(X>999999999)!(X<0)!(X?.E1"."1N.N) X
;;^DD(1.5215,5,.1)
;;=Row Count
;;^DD(1.5215,5,3)
;;=Type a Number between 0 and 999999999, 0 Decimal Digits
;;^DD(1.5215,5,9)
;;=^
;;^DD(1.5215,5,21,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,5,21,1,0)
;;=This field should contain an estimate of the number of rows in the table
;;^DD(1.5215,5,"DT")
;;=2960926
;;^DD(1.5215,6,0)
;;=T_FILE^RNJ19,9O^^0;7^K:+X'=X!(X>999999999)!(X<0)!(X?.E1"."10N.N) X
;;^DD(1.5215,6,.1)
;;=Source File
;;^DD(1.5215,6,1,0)
;;=^.1
;;^DD(1.5215,6,1,1,0)
;;=1.5215^C
;;^DD(1.5215,6,1,1,1)
;;=S ^DMSQ("T","C",$E(X,1,30),DA)=""
;;^DD(1.5215,6,1,1,2)
;;=K ^DMSQ("T","C",$E(X,1,30),DA)
;;^DD(1.5215,6,1,1,"%D",0)
;;=^^1^1^2960902^^
;;^DD(1.5215,6,1,1,"%D",1,0)
;;=Table by source file index
;;^DD(1.5215,6,1,1,"DT")
;;=2960822
;;^DD(1.5215,6,2)
;;=S Y(0)=Y S Y=$S('Y:"",$D(^DIC(+Y)):$P(^(+Y,0),U),1:$O(^DD(+Y,0,"NM","")))
;;^DD(1.5215,6,2.1)
;;=S Y=$S('Y:"",$D(^DIC(+Y)):$P(^(+Y,0),U),1:$O(^DD(+Y,0,"NM","")))
;;^DD(1.5215,6,3)
;;=Type a Number between 0 and 999999999, 9 Decimal Digits
;;^DD(1.5215,6,9)
;;=^
;;^DD(1.5215,6,21,0)
;;=^^1^1^2960926^^^
;;^DD(1.5215,6,21,1,0)
;;=FileMan file number from which table is derived.
;;^DD(1.5215,6,23,0)
;;=^^1^1^2960926^^
;;^DD(1.5215,6,23,1,0)
;;=This may be a subfile number
;;^DD(1.5215,6,"DT")
;;=2960908
;;^DD(1.5215,7,0)
;;=T_UPDATE^D^^0;8^S %DT="EX" D ^%DT S X=Y K:Y<1 X
;;^DD(1.5215,7,.1)
;;=Last Updated
;;^DD(1.5215,7,9)
;;=^
;;^DD(1.5215,7,21,0)
;;=^^1^1^2960926^
;;^DD(1.5215,7,21,1,0)
;;=Date last updated.
;;^DD(1.5215,7,"DT")
;;=2960821
;;^DD(1.5215,8,0)
;;=T_GLOBAL^K^^1;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
;;^DD(1.5215,8,.1)
;;=Global Root
;;^DD(1.5215,8,1,0)
;;=^.1
;;^DD(1.5215,8,1,1,0)
;;=1.5215^D
;;^DD(1.5215,8,1,1,1)
;;=S ^DMSQ("T","D",$E(X,1,30),DA)=""
;;^DD(1.5215,8,1,1,2)
;;=K ^DMSQ("T","D",$E(X,1,30),DA)
;;^DD(1.5215,8,1,1,"%D",0)
;;=^^1^1^2960822^
;;^DD(1.5215,8,1,1,"%D",1,0)
;;=Table by global name. Used for structural study.
;;^DD(1.5215,8,1,1,"DT")
;;=2960822
;;^DD(1.5215,8,3)
;;=A valid M global variable name using {K} for subscripts
;;^DD(1.5215,8,9)
;;=^
;;^DD(1.5215,8,21,0)
;;=^^2^2^2960926^^^^
;;^DD(1.5215,8,21,1,0)
;;=Global variable name. {K} stands for a subscript
;;^DD(1.5215,8,21,2,0)
;;=E.g.: ^DIC(9.4,{K},3,{K},4,{K})
;;^DD(1.5215,8,23,0)
;;=^^1^1^2960926^^^
;;^DD(1.5215,8,23,1,0)
;;=Used to piece out global fragments for columns
;;^DD(1.5215,8,"DT")
;;=2960926
DINIT2B7 ;SFISC/MKO-SQLI FILES ;10:51 AM 30 Mar 1999
+1 ;;22.0;VA FileMan;;Mar 30, 1999
+2 ;Per VHA Directive 10-93-142, this routine should not be modified.
+3 FOR I=1:2
SET X=$TEXT(Q+I)
IF X=""
QUIT
SET Y=$EXTRACT($TEXT(Q+I+1),4,999)
SET X=$EXTRACT(X,4,999)
IF $ASCII(Y)=126
SET I=I+1
SET Y=$EXTRACT(Y,2,999)_$EXTRACT($TEXT(Q+I+1),5,99)
IF $ASCII(Y)=61
SET Y=$EXTRACT(Y,2,999)
SET @X=Y
+4 GOTO ^DINIT2B8
Q QUIT
+1 ;;^DIC(1.5215,0,"GL")
+2 ;;=^DMSQ("T",
+3 ;;^DIC("B","SQLI_TABLE",1.5215)
+4 ;;=
+5 ;;^DIC(1.5215,"%D",0)
+6 ;;=^^6^6^2970806^^^
+7 ;;^DIC(1.5215,"%D",1,0)
+8 ;;=Descriptor of a set of table elements: Includes name and file no.
+9 ;;^DIC(1.5215,"%D",2,0)
+10 ;;=(See SQLI_TABLE_ELEMENTS). Each ^DD(DA) represents a table in a relational
+11 ;;^DIC(1.5215,"%D",3,0)
+12 ;;=model of FileMan. Further, each index represents a table.
+13 ;;^DIC(1.5215,"%D",4,0)
+14 ;;=
+15 ;;^DIC(1.5215,"%D",5,0)
+16 ;;=Each schema contains multiple tables. Each table contains just one primary
+17 ;;^DIC(1.5215,"%D",6,0)
+18 ;;=key, but multiple columns, foreign keys and indicies.
+19 ;;^DD(1.5215,0)
+20 ;;=FIELD^^8^9
+21 ;;^DD(1.5215,0,"DDA")
+22 ;;=N
+23 ;;^DD(1.5215,0,"DT")
+24 ;;=2960913
+25 ;;^DD(1.5215,0,"IX","B",1.5215,.01)
+26 ;;=
+27 ;;^DD(1.5215,0,"IX","C",1.5215,6)
+28 ;;=
+29 ;;^DD(1.5215,0,"IX","D",1.5215,8)
+30 ;;=
+31 ;;^DD(1.5215,0,"IX","E",1.5215,3)
+32 ;;=
+33 ;;^DD(1.5215,0,"NM","SQLI_TABLE")
+34 ;;=
+35 ;;^DD(1.5215,0,"PT",1.5212,3)
+36 ;;=
+37 ;;^DD(1.5215,0,"PT",1.5215,3)
+38 ;;=
+39 ;;^DD(1.5215,0,"PT",1.5216,2)
+40 ;;=
+41 ;;^DD(1.5215,0,"VRPK")
+42 ;;=DI
+43 ;;^DD(1.5215,.01,0)
+44 ;;=T_NAME^RF^^0;1^K:$L(X)>30!($L(X)<3)!'($TR(X,"_")?1U.UN) X
+45 ;;^DD(1.5215,.01,.1)
+46 ;;=Table
+47 ;;^DD(1.5215,.01,1,0)
+48 ;;=^.1
+49 ;;^DD(1.5215,.01,1,1,0)
+50 ;;=1.5215^B
+51 ;;^DD(1.5215,.01,1,1,1)
+52 ;;=S ^DMSQ("T","B",$E(X,1,30),DA)=""
+53 ;;^DD(1.5215,.01,1,1,2)
+54 ;;=K ^DMSQ("T","B",$E(X,1,30),DA)
+55 ;;^DD(1.5215,.01,3)
+56 ;;=Answer must be 3-30 characters in length.
+57 ;;^DD(1.5215,.01,9)
+58 ;;=^
+59 ;;^DD(1.5215,.01,21,0)
+60 ;;=^^1^1^2960926^
+61 ;;^DD(1.5215,.01,21,1,0)
+62 ;;=Table name must be a valid SQL identifier, unique by schema
+63 ;;^DD(1.5215,.01,"DT")
+64 ;;=2960820
+65 ;;^DD(1.5215,1,0)
+66 ;;=T_SCHEMA^RP1.521^DMSQ("S",^0;2^Q
+67 ;;^DD(1.5215,1,.1)
+68 ;;=Schema
+69 ;;^DD(1.5215,1,9)
+70 ;;=^
+71 ;;^DD(1.5215,1,21,0)
+72 ;;=^^1^1^2960926^^
+73 ;;^DD(1.5215,1,21,1,0)
+74 ;;=IEN in SQLI_SCHEMA of the schema to which this table belongs.
+75 ;;^DD(1.5215,1,"DT")
+76 ;;=2960913
+77 ;;^DD(1.5215,2,0)
+78 ;;=T_COMMENT^F^^0;3^K:$L(X)>70!($L(X)<3) X
+79 ;;^DD(1.5215,2,.1)
+80 ;;=Description
+81 ;;^DD(1.5215,2,3)
+82 ;;=Answer must be 3-70 characters in length.
+83 ;;^DD(1.5215,2,9)
+84 ;;=^
+85 ;;^DD(1.5215,2,21,0)
+86 ;;=^^1^1^2960926^^
+87 ;;^DD(1.5215,2,21,1,0)
+88 ;;=A short description of the table
+89 ;;^DD(1.5215,2,"DT")
+90 ;;=2960913
+91 ;;^DD(1.5215,3,0)
+92 ;;=T_MASTER_TABLE^P1.5215'^DMSQ("T",^0;4^Q
+93 ;;^DD(1.5215,3,.1)
+94 ;;=Master Table
+95 ;;^DD(1.5215,3,1,0)
+96 ;;=^.1
+97 ;;^DD(1.5215,3,1,1,0)
+98 ;;=1.5215^E
+99 ;;^DD(1.5215,3,1,1,1)
+100 ;;=S ^DMSQ("T","E",$E(X,1,30),DA)=""
+101 ;;^DD(1.5215,3,1,1,2)
+102 ;;=K ^DMSQ("T","E",$E(X,1,30),DA)
+103 ;;^DD(1.5215,3,1,1,"%D",0)
+104 ;;=^^1^1^2960904^
+105 ;;^DD(1.5215,3,1,1,"%D",1,0)
+106 ;;=Table by master table
+107 ;;^DD(1.5215,3,1,1,"DT")
+108 ;;=2960904
+109 ;;^DD(1.5215,3,3)
+110 ;;=Enter only if this table is an index
+111 ;;^DD(1.5215,3,9)
+112 ;;=^
+113 ;;^DD(1.5215,3,21,0)
+114 ;;=^^1^1^2960926^^^
+115 ;;^DD(1.5215,3,21,1,0)
+116 ;;=The table of which this table is an index. (Only index tables)
+117 ;;^DD(1.5215,3,23,0)
+118 ;;=^^1^1^2960926^^
+119 ;;^DD(1.5215,3,23,1,0)
+120 ;;=In SQL, and in the relational model, an index is just a table.
+121 ;;^DD(1.5215,3,"DT")
+122 ;;=2960913
+123 ;;^DD(1.5215,4,0)
+124 ;;=T_VERSION_FM^NJ9,0^^0;5^K:+X'=X!(X>999999999)!(X<1)!(X?.E1"."1N.N) X
+125 ;;^DD(1.5215,4,.1)
+126 ;;=Version
+127 ;;^DD(1.5215,4,3)
+128 ;;=Type a Number between 1 and 999999999, 0 Decimal Digits
+129 ;;^DD(1.5215,4,9)
+130 ;;=^
+131 ;;^DD(1.5215,4,21,0)
+132 ;;=^^1^1^2960926^^
+133 ;;^DD(1.5215,4,21,1,0)
+134 ;;=The version number is updated by FileMan when ^DD or ^DIC changes.
+135 ;;^DD(1.5215,4,"DT")
+136 ;;=2960926
+137 ;;^DD(1.5215,5,0)
+138 ;;=T_ROW_COUNT^NJ9,0^^0;6^K:+X'=X!(X>999999999)!(X<0)!(X?.E1"."1N.N) X
+139 ;;^DD(1.5215,5,.1)
+140 ;;=Row Count
+141 ;;^DD(1.5215,5,3)
+142 ;;=Type a Number between 0 and 999999999, 0 Decimal Digits
+143 ;;^DD(1.5215,5,9)
+144 ;;=^
+145 ;;^DD(1.5215,5,21,0)
+146 ;;=^^1^1^2960926^^
+147 ;;^DD(1.5215,5,21,1,0)
+148 ;;=This field should contain an estimate of the number of rows in the table
+149 ;;^DD(1.5215,5,"DT")
+150 ;;=2960926
+151 ;;^DD(1.5215,6,0)
+152 ;;=T_FILE^RNJ19,9O^^0;7^K:+X'=X!(X>999999999)!(X<0)!(X?.E1"."10N.N) X
+153 ;;^DD(1.5215,6,.1)
+154 ;;=Source File
+155 ;;^DD(1.5215,6,1,0)
+156 ;;=^.1
+157 ;;^DD(1.5215,6,1,1,0)
+158 ;;=1.5215^C
+159 ;;^DD(1.5215,6,1,1,1)
+160 ;;=S ^DMSQ("T","C",$E(X,1,30),DA)=""
+161 ;;^DD(1.5215,6,1,1,2)
+162 ;;=K ^DMSQ("T","C",$E(X,1,30),DA)
+163 ;;^DD(1.5215,6,1,1,"%D",0)
+164 ;;=^^1^1^2960902^^
+165 ;;^DD(1.5215,6,1,1,"%D",1,0)
+166 ;;=Table by source file index
+167 ;;^DD(1.5215,6,1,1,"DT")
+168 ;;=2960822
+169 ;;^DD(1.5215,6,2)
+170 ;;=S Y(0)=Y S Y=$S('Y:"",$D(^DIC(+Y)):$P(^(+Y,0),U),1:$O(^DD(+Y,0,"NM","")))
+171 ;;^DD(1.5215,6,2.1)
+172 ;;=S Y=$S('Y:"",$D(^DIC(+Y)):$P(^(+Y,0),U),1:$O(^DD(+Y,0,"NM","")))
+173 ;;^DD(1.5215,6,3)
+174 ;;=Type a Number between 0 and 999999999, 9 Decimal Digits
+175 ;;^DD(1.5215,6,9)
+176 ;;=^
+177 ;;^DD(1.5215,6,21,0)
+178 ;;=^^1^1^2960926^^^
+179 ;;^DD(1.5215,6,21,1,0)
+180 ;;=FileMan file number from which table is derived.
+181 ;;^DD(1.5215,6,23,0)
+182 ;;=^^1^1^2960926^^
+183 ;;^DD(1.5215,6,23,1,0)
+184 ;;=This may be a subfile number
+185 ;;^DD(1.5215,6,"DT")
+186 ;;=2960908
+187 ;;^DD(1.5215,7,0)
+188 ;;=T_UPDATE^D^^0;8^S %DT="EX" D ^%DT S X=Y K:Y<1 X
+189 ;;^DD(1.5215,7,.1)
+190 ;;=Last Updated
+191 ;;^DD(1.5215,7,9)
+192 ;;=^
+193 ;;^DD(1.5215,7,21,0)
+194 ;;=^^1^1^2960926^
+195 ;;^DD(1.5215,7,21,1,0)
+196 ;;=Date last updated.
+197 ;;^DD(1.5215,7,"DT")
+198 ;;=2960821
+199 ;;^DD(1.5215,8,0)
+200 ;;=T_GLOBAL^K^^1;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
+201 ;;^DD(1.5215,8,.1)
+202 ;;=Global Root
+203 ;;^DD(1.5215,8,1,0)
+204 ;;=^.1
+205 ;;^DD(1.5215,8,1,1,0)
+206 ;;=1.5215^D
+207 ;;^DD(1.5215,8,1,1,1)
+208 ;;=S ^DMSQ("T","D",$E(X,1,30),DA)=""
+209 ;;^DD(1.5215,8,1,1,2)
+210 ;;=K ^DMSQ("T","D",$E(X,1,30),DA)
+211 ;;^DD(1.5215,8,1,1,"%D",0)
+212 ;;=^^1^1^2960822^
+213 ;;^DD(1.5215,8,1,1,"%D",1,0)
+214 ;;=Table by global name. Used for structural study.
+215 ;;^DD(1.5215,8,1,1,"DT")
+216 ;;=2960822
+217 ;;^DD(1.5215,8,3)
+218 ;;=A valid M global variable name using {K} for subscripts
+219 ;;^DD(1.5215,8,9)
+220 ;;=^
+221 ;;^DD(1.5215,8,21,0)
+222 ;;=^^2^2^2960926^^^^
+223 ;;^DD(1.5215,8,21,1,0)
+224 ;;=Global variable name. {K} stands for a subscript
+225 ;;^DD(1.5215,8,21,2,0)
+226 ;;=E.g.: ^DIC(9.4,{K},3,{K},4,{K})
+227 ;;^DD(1.5215,8,23,0)
+228 ;;=^^1^1^2960926^^^
+229 ;;^DD(1.5215,8,23,1,0)
+230 ;;=Used to piece out global fragments for columns
+231 ;;^DD(1.5215,8,"DT")
+232 ;;=2960926