XSD架构文件必须在SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class被标注?架构、文件、XSD、SQLXMLBULKLOADLib

由网友(我不过是想要一句晚安)分享简介:下面是一个例子使用SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class - Here is an example to use SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class - [STAThread]static void Main(string[] ar...

下面是一个例子使用SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class -

Here is an example to use SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class -

[STAThread]
   static void Main(string[] args)
   {   
         try
         {
            SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class objBL = new SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class();
            objBL.ConnectionString = "Provider=sqloledb;server=server;database=databaseName;integrated security=SSPI";
            objBL.ErrorLogFile = "error.xml";
            objBL.KeepIdentity = false;
            objBL.Execute ("schema.xml","data.xml");
         }
         catch(Exception e)
         {
         Console.WriteLine(e.ToString());
         }
   }

看来schema.xml中必须使用SQL的信息,使导入成功的注解。普通XSD文件无法正常工作。

It seems that schema.xml must be annotated with sql information to make importing successful. Regular xsd file does not work.

有任何工具或方法来自动化的注释信息的基础上XSD文件的产生?我找不到任何通过互联网搜索。我不知道SSIS如何能做到这一点。是否有任何组件这样做,所以我可以将其包含在我的.net应用程序?

Is there any tools or ways to automate the generation of annotate information basing on xsd file? I could not find any through Internet Search. I wonder how SSIS can achieve this. Is there any component doing this so I can include it in my .NET application?

推荐答案

不幸的是,我不相信有,你必须手动添加这些东西,据我所知。有利的一面是,这是不是太困难,不过,提供你不打任何奇怪的打嗝。

Unfortunately I don't believe there is, you have to add these things manually, as far as I'm aware. The upside is that it isn't too difficult, though, providing you don't hit any weird hiccups.

如果你是他发表您的XSD和表结构,我可以帮你的忙。

If you post your XSD and table structure maybe I can give you a hand.

阅读全文

相关推荐

最新文章