BUG: Certain extended properties won't add

These were all from one table and were added to ScriptsIgnoredOnImport.sql

EXEC sp_addextendedproperty N'MS_Description', N'Instructor Created Homework Assignments', 'SCHEMA', N'dbo', 'TABLE', N'homework', NULL, NULL
GO
EXEC sp_addextendedproperty N'MS_Description', N'user_id of creator', 'SCHEMA', N'dbo', 'TABLE', N'homework', 'COLUMN', N'creator'
GO
EXEC sp_addextendedproperty N'MS_Description', N'0 - type A 2 - type B 3 - type C 4 - External', 'SCHEMA', N'dbo', 'TABLE', N'homework', 'COLUMN', N'homeworkformat'
GO
EXEC sp_addextendedproperty N'MS_Description', N'0 - type A 1 - type B 3 - type C 4 - type D 5 - Unknown', 'SCHEMA', N'dbo', 'TABLE', N'homework', 'COLUMN', N'exerciseformat'

Nothing about them stands out that I can see and I have a lot of extended properties already in there.



Answer this question

BUG: Certain extended properties won't add

  • Nanja Raje Urs

    Have we resolved this issue, or are we still working on it



  • kybubbles

    If that would be the case they would end up in the ScriptsIgnored.sql file, is that the case

    -GertD


  • DragonC#

    I created a table on an empty DB with following script, and added your extended properties to that table. Then I did importing schema, all those extended properties show up in homework table script. I tried with case sensitive and case insensitive databases, they all worked.

    After importing the schema, is the script file for homework table there in the project And are those three columns there in the script

    CREATE TABLE [homework]

    (

    creator nvarchar(50) not null,

    homeworkformat nvarchar(20),

    exerciseformat nvarchar(30)

    )



  • Ravel

    Import Schema

    I have tons of very similar ones already in my DB project for tables and columns and those got imported fine. "MS_Description" in particular is used for documentation and maybe doc generating packages pick up on it to add descriptions to CHM files of your DB schema.


  • Kent Boogaart

    Liangxiao Zhu - MSFT wrote:

    Hi, we tried the script you emailed to Gert. But we can not repro the issue you mentioned. The extended property gets imported together with the Table script after invoking "Import Script" on a project. We also tried run the script in a database, and import schema from that database to a new project, those extended property still get imported together with the Table.

    How you tried to create a new project, and import the script What happened after that

    Thanks,

    Liangxiao



    I am not a SideOut but we are having exactly the same issue. The extended properties are not imported to the project properly. We tried doing both Write Updates after schema compare and Import Script and in both cases the extended properties are included in the ScriptsIgnoredOnImport.sql. During the Import Script it even shows the warning that some statements were not loaded. I did try to create a new project and performed a schema import and it worked properly, so the bug is not happening when you do import schema but will be a problem if you have tables in the project but script will add extended properties on that table.

    It is my speculation but I would guess that Visual Studio can't figure out in which source file the extended properties should go during import script and it is not a problem during schema import since the source files for tables are being generated and all information for each table is collected together.

  • anubisascends

    From those information you provided, I can not figure what is wrong here. Do you mind share out your script, so I can do further investigation

  • nicola_italia

    Steven, I e-mailed my schema script on Feb 26th, but I haven't heard back yet.
  • Travis75

    I'm not sure if I'm allowed to post the full table exact info. Can I e-mail it to you
  • Sarath.

    You can mail it to me gert dot drapers at microsoft dot com. I will pass it on to Liangxiao

    -GertD


  • jw700

    Sideout -

    Have you resolved your issue If not, if you can follow up with the answer to Liangxiao's questions, we may be able to help.

    thanks,



  • Mark Beiley

    Hi, we tried the script you emailed to Gert. But we can not repro the issue you mentioned. The extended property gets imported together with the Table script after invoking "Import Script" on a project. We also tried run the script in a database, and import schema from that database to a new project, those extended property still get imported together with the Table.

    How you tried to create a new project, and import the script What happened after that

    Thanks,

    Liangxiao



  • Io2006

    Are you performing an import schema or import script

    All these are Microsoft internal extended properties used by SSMS, and we normally filter these out.

    -GertD


  • clstephenson

    Another one

    EXEC sp_addextendedproperty N'MS_Description', N'A/B (parens)', 'SCHEMA', N'dbo', 'TABLE', N'xYData', NULL, NULL

    In this case I suspect either the slash or parentheses. However if it's good enough for SQL Server 2005 to accept, it should be good enough for DB Pro.


  • txteacher

    The table and columns are there but the extended properties keep ending up in the ignored file. I opened the table sql and added the extended properties in by hand and they seem to be sticking though.
  • BUG: Certain extended properties won't add