This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ODBC Request from C# windows service unable to connect to Relativity for RM

ODBC Request from C# windows service unable to connect.

Running into an issue with a C# application running as a windows service being unable to read from the odbc driver.  When the application is running from Visual Studio it works as expected. Once it is installed as a Windows services it generates this error on the execution of the query(below) 

The Error

{"ERROR [HY000] [Micro Focus][Relativity for RM][CRDM]Filename is invalid.\r\nERROR [HY000] [Micro Focus][Relativity for RM]Unable to open table: ORDER_HEADER_FILE."}

The query 

SELECT OrderNo, OrderCustContact, OrderShipToName, OrderShipToAddress1, OrderShipToAddress2, OrderShipToAddr3,
OrderShipToCity, OrderShipToState, OrderShipToZip, OrderCustPhoneNo, OrderShipViaCode, OrderTotalSaleAmount, OrderFreightPayCode,OrderPurchaseOrderNo, OrderShipToNo, OrderShipToCountry FROM ORDER_HEADER_FILE

  • Suggested Answer

    0

    The first thing I would check is how the pathname(s) in the file connections are structured.  

    If pathnames are specified as relative paths, the paths are relative to the directory containing the catalog.  Perhaps the catalog got moved, rendering relative path names invalid.

  • 0 in reply to 

    Tom thanks for the thoughts, I did check and the DNS="value" is all the application is using to make the ODBC connection per the documentation I could find. The file is local and the ODBC driver is using a absolute path.  Any other ideas you might have would be appreciated ?

  • 0 in reply to 

    Here is the full Error I am seeing. 

    System.Data.Odbc.OdbcException (0x80131937): ERROR [HY000] [Micro Focus][Relativity for RM][CRDM]Filename is invalid.
    ERROR [HY000] [Micro Focus][Relativity for RM]Unable to open table: ORDER_HEADER_FILE.

  • 0 in reply to 

    Do you have the Relativty Designer or the Relativity DBA?  The connection to which I refer is the pathname stored in the metadata of the catalog.  Either the Designer or the DBA is needed to investigate these values.

  • 0 in reply to 

    Thanks again Tom for the information, I was advised the files paths are relative in the file.

  • 0 in reply to 

    Ok.  This is as I expected.

    Typical in this situation the data files are located in directories subordinate to the directory containing the catalog.

    If somehow in the transition between Visual Studio and a Windows service the relationship between the catalog and the data files is changed, Relativity will not be able to find the file when it needs to be opened to fetch data for the associated table query.

    Does this error happen on only a single table, or on more than one table?

  • 0 in reply to 

    This happens on more than one table.  I am trying to access Two to be exact and both respond with this behavior. 

  • 0 in reply to 

    This happens on more than one table.  I am trying to access Two to be exact and both respond with this behavior.