I have been able to use java to connect to the xdbc server but not using
.net

 

Here is the java example that has worked:

 

java  -classpath
"d:/temp/xcc/examples/marklogic-xcc-4.2.3.jar;d:/temp/xcc/examples/marklogic
-xcc-examples-4.2.3.jar" com.marklogic.xcc.examples.ContentFetcher
xcc://admin:pass@localhost:8003/CDADatabase /CDA/foo.xml -o
d:/temp/xcc/foo_out.xml

 

 

the .net code has the following:

 

Uri serverUri = new Uri("xcc://admin:pass@localhost:8003/CDADatabase");

 

SimpleQueryRunner sqr = new SimpleQueryRunner(serverUri);

 

 

SimpleQueryRunner uses : ContentSource cs =
ContentSourceFactory.NewContentSource(serverUri)

And this throughs exception: and I get the following error:

 

System.Xml.XmlException: Data at the root level is invalid. Line 1, position
1.

   at System.Xml.XmlTextReaderImpl.Throw(Exception e)

   at System.Xml.XmlTextReaderImpl.Throw(String res, String arg)

   at System.Xml.XmlTextReaderImpl.ParseRootLevelWhitespace()

   at System.Xml.XmlTextReaderImpl.ParseDocumentContent()

  at System.Xml.XmlTextReaderImpl.Read()

   at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean
preserveWhitespace)

   at System.Xml.XmlDocument.Load(XmlReader reader)

   at System.Xml.XmlDocument.LoadXml(String xml)

 

 

 

 

is there something simple I am missing.. ?!!

 

Thanks.

 

 

 

_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to