XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Show tree view Topic
Go to previous topicPrev TopicGo to next topicNext Topic
Postnext
andre goldiSubject: Specifying the SEF File Location ...
Author: andre goldi
Date: 26 Aug 2011 09:41 AM
Originally Posted: 26 Aug 2011 09:20 AM
Having a Java-Project like this

MyProject
- lib
- EDI.jar
- XMLConverters.jar

- src
- stylusstudio
- editoxml
my.sef
my.xquery
- xmltoedi
myproject.prj
- test
- data
- editoxml
my.edi
- xmltoedi

How do I have to specify the SEF file location ? It has to be a relative path.
For example this does not work in the xquery-file:
file:///..\src\stylusstudio\editoxml\my.sef?..\..\..\test\daten\editoxml\my.edi

I read this:

http://www.stylusstudio.com/docs/v2010/d_flatfileconversion51.html#wp691009

thats why I set the path like this.

But Stylus Studio does not find the ".sef" File. The project is in SVN so I can not use an absosule Path.

Postnext
Ivan PedruzziSubject: Specifying the SEF File Location ...
Author: Ivan Pedruzzi
Date: 26 Aug 2011 05:13 PM

I was under the impression that you were planning to use the API to load the SEF file as we discussed here
http://www.stylusstudio.com/ssdn/default.asp?action=9&read=9496&fid=57#29443

Could you post the stack trace when the error occurs?
Is the URL used inside the query source or the document is bound to an external parameter?

Relative paths for the SEF file are not supported in the custom URL resolver, I also advice against their use.

If you use something like the following you have place your SEF files in MyProject/lib/CustomEDI
converter:EDI:user=code99.sef?code99.x12

The EDI file can use a relative path that will be calculated at run-time, relative to the current working directory.

Building full file paths in your Java code is still the safer and more portable approach.

Hope this helps
Ivan













Postnext
andre goldiSubject: Specifying the SEF File Location ...
Author: andre goldi
Date: 29 Aug 2011 01:55 AM
Hy Ivan,

yes I am using the API as you said and it is working fine. The problem is another now.
The Project I described is a SVN-Project within the Stylus Studio project file "myproject.prj" exists. So when creating the Stylus Studio Project file and doing the mapping (creating "sef" files, creating xquery files and so on) Stylus Studio uses absolute paths. For me it is ok like this. But if another person checks out the project and then opens the Stylus Studio Project file he/she will have to change all the paths Stylus Studio is using.

Posttop
Ivan PedruzziSubject: Specifying the SEF File Location ...
Author: Ivan Pedruzzi
Date: 31 Aug 2011 12:41 PM

You are right while the tale of the URL is adjusted automatically when "use relative path" is checked, the SEF file path is not fixed-up.

The only suggestion I have is to store SEF files under the
<XML Converter Lib>\CustomEDI

Change your URLs as follow; when the SEF URL is a file name without path, XML Converters tries to locate the file in the above path

converter:EDI:my.sef?<full path here>\my.edi


Hope this helps
Ivan Pedruzzi
Stylus Studio Team

 
Go to previous topicPrev TopicGo to next topicNext Topic
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2016 All Rights Reserved.