📄 xmltype.xfm
字号:
inherited XMLTypeFrame: TXMLTypeFrame Width = 752 VertScrollBar.Range = 118 object ToolBar1: TPanel Left = 0 Top = 0 Width = 752 Height = 48 Align = alTop BevelOuter = bvNone TabOrder = 0 object Panel1: TPanel Left = 0 Top = 0 Width = 560 Height = 24 BevelOuter = bvNone Color = 170 ParentColor = False TabOrder = 0 object btOpen: TSpeedButton Left = 1 Top = 1 Width = 82 Height = 22 Caption = 'Open' Flat = True Transparent = False OnClick = btOpenClick end object btClose: TSpeedButton Left = 84 Top = 1 Width = 82 Height = 22 Caption = 'Close' Flat = True Transparent = False OnClick = btCloseClick end object btCreate: TSpeedButton Left = 388 Top = 1 Width = 85 Height = 22 Hint = 'Create XML objects' Caption = 'Create' Flat = True Font.Color = clText Font.Height = 11 Font.Name = 'MS Sans Serif' Font.Pitch = fpVariable Font.Style = [fsBold] ParentFont = False Transparent = False OnClick = btCreateClick end object btDrop: TSpeedButton Left = 474 Top = 1 Width = 85 Height = 22 Hint = 'Drop XML objects' Caption = 'Drop' Flat = True Font.Color = clText Font.Height = 11 Font.Name = 'MS Sans Serif' Font.Pitch = fpVariable Font.Style = [fsBold] ParentFont = False Transparent = False OnClick = btDropClick end object DBNavigator1: TDBNavigator Left = 167 Top = 1 Width = 220 Height = 22 DataSource = dsData Flat = True TabOrder = 0 end end object Panel3: TPanel Left = 0 Top = 24 Width = 516 Height = 23 BevelOuter = bvNone Color = 170 ParentColor = False TabOrder = 1 object SpeedButton2: TSpeedButton Left = 250 Top = 0 Width = 82 Height = 22 Caption = 'Transform' Flat = True Transparent = False OnClick = SpeedButton2Click end object btAddRecord: TSpeedButton Left = 1 Top = 0 Width = 82 Height = 22 Caption = 'Add Record' Flat = True Transparent = False OnClick = btAddRecordClick end object btShowCountry: TSpeedButton Left = 84 Top = 0 Width = 82 Height = 22 Caption = 'GetSchema' Flat = True Transparent = False OnClick = btShowCountryClick end object SpeedButton1: TSpeedButton Left = 167 Top = 0 Width = 82 Height = 22 Caption = 'Extract' Flat = True Transparent = False OnClick = SpeedButton1Click end object Panel2: TPanel Left = 333 Top = 0 Width = 182 Height = 22 BevelOuter = bvNone Color = clButton ParentColor = False TabOrder = 0 object Label1: TLabel Left = 15 Top = 4 Width = 46 Height = 13 Caption = 'Based on:' end object RadioButton1: TRadioButton Left = 66 Top = 3 Width = 61 Height = 17 Caption = 'Schema' TabOrder = 0 TabStop = False OnClick = RadioButton1Click end object RadioButton2: TRadioButton Left = 128 Top = 3 Width = 52 Height = 17 Caption = 'Lob' Checked = True TabOrder = 1 OnClick = RadioButton1Click end end end end object DBGrid: TDBGrid Left = 0 Top = 48 Width = 752 Height = 186 Align = alClient DataSource = dsData TabOrder = 1 TitleFont.Color = clBlack TitleFont.Height = 11 TitleFont.Name = 'helvetica' TitleFont.Pitch = fpVariable TitleFont.Style = [] end object DBMemo1: TDBMemo Left = 0 Top = 234 Width = 752 Height = 70 Align = alBottom DataField = 'XMLField' DataSource = dsData TabOrder = 2 end object dsData: TDataSource DataSet = Query Left = 24 Top = 80 end object Query: TSmartQuery SQL.Strings = ( '') Debug = True FetchRows = 20 LockMode = lmNone RefreshOptions = [roAfterInsert, roAfterUpdate] ObjectView = True Left = 168 Top = 104 end object OraSQL: TOraSQL Debug = True Left = 200 Top = 104 end object scCreate: TOraScript SQL.Strings = ( 'declare' 'doc varchar2(2000) :=' #39'<schema targetNamespace="http://www.oracle.com/PO.xsd"' ' xmlns:po="http://www.oracle.com/PO.xsd"' ' xmlns="http://www.w3.org/2001/XMLSchema">' ' <complexType name="PurchaseOrderType">' ' <sequence>' ' <element name="PONum" type="decimal"/>' '' ' <element name="Company">' ' <simpleType>' ' <restriction base="string">' ' <maxLength value="100"/>' ' </restriction>' ' </simpleType>' ' </element>' '' ' <element name="Item" maxOccurs="1000">' ' <complexType>' ' <sequence>' ' <element name="Part">' ' <simpleType>' ' <restriction base="string">' ' <maxLength value="1000"/>' ' </restriction>' ' </simpleType>' ' </element>' '' ' <element name="Price" type="float"/>' '' ' </sequence>' ' </complexType>' ' </element>' '' ' </sequence>' ' </complexType>' ' <element name="PurchaseOrder" type="po:PurchaseOrderType"/>' '</schema>'#39';' 'begin' ' dbms_xmlschema.registerSchema('#39'http://www.oracle.com/PO.xsd'#39', ' + 'doc);' 'end;' '/' '' 'CREATE TABLE xmlschema_type (' ' ID NUMBER PRIMARY KEY,' ' XMLField SYS.XMLType' ')' 'XMLTYPE COLUMN XMLField' ' XMLSCHEMA "http://www.oracle.com/PO.xsd"' ' ELEMENT "PurchaseOrder";' '' 'CREATE TABLE xml_type (' ' ID NUMBER PRIMARY KEY,' ' XMLField XMLTYPE' ');' '' 'INSERT INTO xmlschema_type VALUES(' ' 1,' ' XMLTYPE('#39'<PurchaseOrder ' 'xmlns="http://www.oracle.com/PO.xsd" xmlns:xsi="http://www.w3.or' + 'g/2001/XMLSchema-instance" xsi:schemaLocation="http://www.oracle' + '.com/PO.xsd http://www.oracle.com/PO.xsd">' ' <PONum>73</PONum>' ' <Company>Oracle Corp</Company>' ' <Item>' ' <Part>9i Doc Set</Part>' ' <Price>130</Price>' ' </Item>' ' <Item>' ' <Part>8i Doc Set</Part>' ' <Price>946</Price>' ' </Item>' '</PurchaseOrder>'#39 ' )' ');' '' 'INSERT INTO xml_type VALUES(' ' 1,' ' XMLTYPE('#39'<PurchaseOrder>' ' <PONum>73</PONum>' ' <Company>Oracle Corp</Company>' ' <Item>' ' <Part>9i Doc Set</Part>' ' <Price>130</Price>' ' </Item>' ' <Item>' ' <Part>8i Doc Set</Part>' ' <Price>946</Price>' ' </Item>' '</PurchaseOrder>'#39 ' )' ');' '' 'INSERT INTO xml_type VALUES(' ' 2,' ' XMLTYPE(' ' '#39'<root>value</root>'#39 ' )' ');' '' 'COMMIT;') Left = 224 Top = 56 end object scDrop: TOraScript SQL.Strings = ( 'DROP TABLE xml_type;' '' 'DROP TABLE xmlschema_type;') Left = 256 Top = 56 endend
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -