php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57231 Extending simple types as complex types
Submitted: 2006-09-14 04:32 UTC Modified: 2017-01-10 08:12 UTC
From: simonslaws at googlemail dot com Assigned: tuscany 444 (profile)
Status: Suspended Package: SCA_SDO (PECL)
PHP Version: 5.1.4 OS: XP
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: simonslaws at googlemail dot com
New email:
PHP Version: OS:

 

 [2006-09-14 04:32 UTC] simonslaws at googlemail dot com
Description:
------------
SDO won't load my complex type that extends a simple type in order to add an attribute

Reproduce code:
---------------
I believe this is valid schema

  <complexType name="ComplexTypeExtendingSimpleTypeType">
    <simpleContent>
      <extension base="tns:SimpleTypeWithNameType">
		<attribute name="AddedByExtension" type="string"/>
      </extension>
    </simpleContent>  
  </complexType>
                 
  <element name="RootElement25">
    <complexType>
      <sequence>
        <element name="ComplexTypeExtendingSimpeType" type="tns:ComplexTypeExtendingSimpleTypeType"/>            
      </sequence>
    </complexType>
  </element>

Expected result:
----------------
To be loaded into the SDO type model 

Actual result:
--------------
Exception in PHP Interop test: Cannot add property AddedByExtension of type commonj.sdo#String to this data type http://www.apache.org/tuscany/interop#ComplexTypeExtendingSimpleTypeType

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-09-14 04:36 UTC] simonslaws at googlemail dot com
I get the same result for restriction also:

  <complexType name="ComplexTypeSimpleContentRestrictingComplexTypeType">
    <simpleContent>
      <restriction base="tns:ComplexTypeExtendingSimpleTypeType">
        <attribute name="AddedByExtension" type="NCName" />
      </restriction>
    </simpleContent>  
  </complexType>     
                 
  <element name="RootElement27">
    <complexType>
      <sequence>
        <element name="ComplexTypeSimpleContentRestrictingComplexType" type="tns:ComplexTypeSimpleContentRestrictingComplexTypeType"/>                        
      </sequence>
    </complexType>
  </element>
 [2007-04-24 18:08 UTC] cem@php.net
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PECL.


I think you're probably describing a Tuscany problem, but there's no link in the defect and I don't see an obvious issue which corresponds. Please either add a link, or if this is a problem with the PHP extension, confirm that it still exists with the latest release.
 [2007-05-09 07:54 UTC] depotnet at free dot fr
Please find above my description of the problem.
It seems that you can't have a complex type that extends a simple type.

I tried with your new version of SDO 1.2.0, same problem.

<?php 
try { 
   $xmldas = SDO_DAS_XML::create("./ddex_xsd/dsr.xsd"); 
  print($xmldas); 
} catch (SDO_Exception $e) { 
   print($e->getMessage()); 
} 
?> 

but I get this execption : 
Cannot add property Namespace of type commonj.sdo#String to this data 
type http://ddex.net/xml/2006/dsrm/10#CommercialModelType 

Official XSD file can be downloaded here : 
http://ddex.net/xml/2006/dsrm/10/dsr.xsd

WFX
 [2007-05-09 09:15 UTC] cem@php.net
The PHP SDO implementation depends on the Tuscany C++ SDO library, and often bugs can only be fixed by getting them implemented in Tuscany. So when a SCA_SDO maintainer raises an SDO bug in this tracker, our rule is that they should always provide a link to the relevant Tuscany defect, to make sure we can trace progress. This particular bug was moved (along with a few others) to feedback state because the there was no runnable testcase and no link to a Tuscany defect. 

Of course when the person raising the bug is not a maintainer, we don't expect you to do this!
 [2007-05-14 07:10 UTC] simonslaws at googlemail dot com
This problem should remain open. It is a long standing issue with Tuscany C++ SDO recorded in JIRA TUSCANY-444. Looking back at this I note that Pete added comments to the JIRA a good while back but a solution was not developed. I'll go take a look and see what state the code is in.
 [2007-05-15 09:23 UTC] cem@php.net
Simon, the way we handle these is to assign the bug to tuscany, not to yourself, and to add a link in the defect so that interested parties don't have to find their own way to the Tuscany JIRA:

http://issues.apache.org/jira/browse/TUSCANY-444
 [2017-01-10 08:12 UTC] kalle@php.net
-Status: Assigned +Status: Suspended
 [2017-01-10 08:12 UTC] kalle@php.net
Suspending this report as the extension have not had a release for almost 9 years.  Please revive this if the extension once again shows life
 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Sun Nov 29 05:01:23 2020 UTC