none
Changing schema namespaces generated by WCF ConsumeAdapterService RRS feed

Answers

  • I may be able to save you some time.  I had a similar issue.

    I changed the target namespaces on my WCF SQL Adapter-generated schemas.  Everything looked fine in Visual Studio.  Schemas validated, message instances tested out OK, etc.  But at runtime the SQL adapter would not process the messages correctly.  I was sending composite INSERTs.  The error I was seeing was that the "start element with the name 'Insert' and namespace {whatever} was unexpected."

    The INSERTs would work fine if I kept the original generated namespaces.  Would not work if I replaced them with my own namepsaces.  I opened up a ticket with Microsoft Premier support.  Together we came to the conclusion that adapter is dependent on the namespaces it generates, and that they shouldn't be changed.  My guess is the adapter uses the namespace to find the proper path to the database tables, sp, etc.

    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Thursday, January 21, 2010 3:15 PM
  • Hi Steve,

    What twhensly is saying is true. In past I experienced the samething when I generated schema's with BizTalk Enterprise Adapters, version before Adapter Pack 1.0/2.0. I was generating schema's from Oracle tables and winded up with [] in namespce that caused some problems when I wanted to process return messages from Oracle. I changed the namespace and run into: Finding the document specification by message type errors. I changed namespace back to original and problems were gone. I guess you have to live with generated namespaces by the adapter.

    Cheers,

    Steef-Jan
    BizTalk Server
    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Thursday, January 21, 2010 3:23 PM
    Moderator
  • I too have had some problems here. I wrote a blog post on some of my troubles: http://msinnovations.spaces.live.com/blog/cns!62E68922E47BC425!756.entry. The database schema is one thing I know cannot be changed without regenerating the schema.

    Also, if you try to change the namespace you will likely have to drill into the generated code of the maps and orchestrations because this is where some of the namespaces are hard coded. One way to get around this is to delete all of the .odx.cs and .btm.cs files and rebuild because this will regenerate the .cs files that form the actual source for the BizTalk artifacts.

    Thanks,


    If this answers your question, please use the "Answer" button to say so | Ben Cline
    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Friday, January 22, 2010 4:23 PM
    Moderator

All replies

  • Hi Steve,

    Have you restarted the host instances. It seems that if schema's have been deployed properly, the previous one are still in cache.

    Cheers,

    Steef-Jan Wiggers (http://soa-thoughts.blogspot.com/).

    If you feel this answers your question, please mark it accordingly it will be much appreciated.
    BizTalk Server
    Wednesday, January 20, 2010 9:55 PM
    Moderator
  • Hi Steef-Jan,

    Yes, I have re-started the Host Instances.

    Steve
    Thursday, January 21, 2010 2:31 PM
  • I may be able to save you some time.  I had a similar issue.

    I changed the target namespaces on my WCF SQL Adapter-generated schemas.  Everything looked fine in Visual Studio.  Schemas validated, message instances tested out OK, etc.  But at runtime the SQL adapter would not process the messages correctly.  I was sending composite INSERTs.  The error I was seeing was that the "start element with the name 'Insert' and namespace {whatever} was unexpected."

    The INSERTs would work fine if I kept the original generated namespaces.  Would not work if I replaced them with my own namepsaces.  I opened up a ticket with Microsoft Premier support.  Together we came to the conclusion that adapter is dependent on the namespaces it generates, and that they shouldn't be changed.  My guess is the adapter uses the namespace to find the proper path to the database tables, sp, etc.

    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Thursday, January 21, 2010 3:15 PM
  • Hi Steve,

    What twhensly is saying is true. In past I experienced the samething when I generated schema's with BizTalk Enterprise Adapters, version before Adapter Pack 1.0/2.0. I was generating schema's from Oracle tables and winded up with [] in namespce that caused some problems when I wanted to process return messages from Oracle. I changed the namespace and run into: Finding the document specification by message type errors. I changed namespace back to original and problems were gone. I guess you have to live with generated namespaces by the adapter.

    Cheers,

    Steef-Jan
    BizTalk Server
    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Thursday, January 21, 2010 3:23 PM
    Moderator
  • I too have had some problems here. I wrote a blog post on some of my troubles: http://msinnovations.spaces.live.com/blog/cns!62E68922E47BC425!756.entry. The database schema is one thing I know cannot be changed without regenerating the schema.

    Also, if you try to change the namespace you will likely have to drill into the generated code of the maps and orchestrations because this is where some of the namespaces are hard coded. One way to get around this is to delete all of the .odx.cs and .btm.cs files and rebuild because this will regenerate the .cs files that form the actual source for the BizTalk artifacts.

    Thanks,


    If this answers your question, please use the "Answer" button to say so | Ben Cline
    • Marked as answer by Steve McDonald Tuesday, January 26, 2010 3:29 PM
    Friday, January 22, 2010 4:23 PM
    Moderator
  • Thanks to all who replied.  I have the answer I needed.
    Tuesday, January 26, 2010 3:30 PM
  • hey

     what did you do? I am stuck with this error forever and need help with it?


    • Edited by 03mark03 Wednesday, May 22, 2013 7:01 PM
    Wednesday, May 22, 2013 6:50 PM
  • The easiest solution for these issues is

    Create a common.schemas project 

    Add all SQL schema in it 

    then create other projects  which will be add reference to  common.schemas project.

    So basically in biztalk admin console  you will have only one schema for sql sp with unique targetnamespace and # schema combination

    you cannot change auto generated schema target namespace

    Now the hack part 

    If you have to use  2 schema's of same stored procedure and you just want two target namespace

    create stored procedure with different schema or different procedure name

    example :

    dbo.[ss_getMattersValidation]
     

     

     Elite.[ss_getMattersValidation]

    or

    dbo.[ss_getMattersValidation]

    dbo.[ss_getMattersValidation_forbiztalk]


    Monday, August 28, 2017 5:14 PM
  • Its autogenerated schema which is used by Biztalk adapter  to determine Sql storedprocedure and table names

    Nothing to do with restart host if you change target namespace from 

    http://schemas.microsoft.com/Sql/2008/05/TableOp/dbo/MYTABLENAME 

    http://schemas.microsoft.com/Sql/2008/05/TableOp/dbo/MYTABLENAME_1

    you have to create MYTABLENAME_1

    Same for stored procedure.

    So you cannot edit targetnamespace of a adaptergenerated  schema .

    If you feel this answers your question, please mark it accordingly it will be much appreciated.


    BizTalk Server


    • Edited by JIN THAKUR Monday, August 28, 2017 6:25 PM
    Monday, August 28, 2017 6:25 PM