Navision 4.0 SP3 - SQL and Create eletronic invoices

hairamhairam Member Posts: 27
edited 2007-05-14 in SQL General
Hi all.
I encounted a problem when writing eletronic invoices from a SQL server.

I had the problem that Navision wrote a error message that it was an invalid OIOXML path I had specified in sales setup.
I tried quite a few things. I took a copy of the database and started a native database with the same information. It now had no problems making the electronic invoices.
Ok so i browsed though the code and found that if I outcommeted these lines in 13609 - OIOXML Export Sales invoice

IF NOT OIOXMLDocumentEncode.TestFolder(SalesSetup."OIOXML Invoice Path") THEN
SalesSetup.FIELDERROR(SalesSetup."OIOXML Invoice Path", Text000);
XMLdocOut.save(STRSUBSTNO('%1\%2.xml', SalesSetup."OIOXML Invoice Path", "No."));

If I did that it made the XML fine and ofcourse dident send a error message. I do not feel good about changing any of the official code.
Anyone seen or heard of this before, and is there a fix for it or something?

Thanks
Jacob Egeberg

Comments

  • Marije_BrummelMarije_Brummel Member, Moderators Design Patterns Posts: 4,262
    Can it be that it is not a SQL problem, but your server does not have access to the specified path?
  • hairamhairam Member Posts: 27
    I thought so too.
    But, I can get it to work without any problems if I run Navision connected to a Native database (The same data, made via a backup from the SQL)
    The same path everything, nothing outcommented it works fine. it.
  • MbadMbad Member Posts: 344
    How could this code


    File.SETRANGE(Path, FolderName); // foldername = your path
    File.SETRANGE("Is a file", FALSE);
    File.SETRANGE(Name, '.');
    EXIT(File.FIND('-'));

    differ from native to sql.
    My guess is that it is a permission problem.
  • hairamhairam Member Posts: 27
    Exactly I cannot see it either. But fact is if I ommit those 4 lines it works.

    I think you are right in that it is some form of SQL permission.
    But then the 10000 DKK :) question.
    What SQL permission could have this effect?

    Jacob Egeberg
  • Saint-SageSaint-Sage Member Posts: 92
    Is SQL Server running with it's own login? Check the services configuration for it, if they created a login just for SQL Server they may not have added it to the correct group or added it's login in the file ACLS.

    No one loves you like the one who created you...
  • krikikriki Member, Moderator Posts: 9,112
    [Topic moved from Navision forum to SQL General forum]
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


Sign In or Register to comment.