Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MAS 90 ODBC Connection works in Console, not in Web

Status
Not open for further replies.

sactowngirl

Programmer
May 30, 2008
18
0
0
I have spent a couple of days in this problem. I have a Console Application in C# that connects to MAS and displays the data successfully. I tried to pass this code (EXACT CODE, EXACT CONNECTION) to a Web App (ASP.NET) and I keep getting this error:
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
when it tries to open the connection.

Why is this not working on ASP.NET but it is on a Console App? I'm using ProvideX ODBC Driver v.4.10.1001.

Any help would be great

Thanks.

 
Ok, I have new info now:

My DSN was a User and not a System one. So I created a System DSN with the same properties of the original one and I also gave Read permissions for my ASPNET user on the ODBC.INI registry key of my Data Source. Now I don't get any error... but the application hangs in the conn.Open() forever...

Any ideas?
 
Did you put in the username, password, and company code into the ODBC configuration?

Dawn
 
I put the username, password and company code into the connection string. I had to download the ProvideX ODBC Drive 4.21.1000, that kinda help the problem. Now, it's opening the connection and pulling the data correctly but just 2 times!!! After the 3rd load of my page the page breaks and display the following message:

System.Data.Odbc.OdbcException: ERROR [S0000] [ProvideX][ODBC Driver][FILEIO]Table is not accessible

I don't think it's an access/permission issue anymore since it's pulling the data correctly twice in a row. I tried different tables and it's always after the 3rd load when it breaks.

This is my log file:
Driver version: 4.21.1000
ISAMOpen: UserID='***', length=3
------------------------------
SELECT * FROM IMC_WarehouseCode

GetAccessibleTables:<table=IMC_WarehouseCode> Open catalog(s) \\**********\MAS90 , available 1038 table(s)
<IMC_WarehouseCode> Open file \\********\MAS90\MAS_E\IMETL\imcetl.soa, maxksz=4
Accessing table IMC_WarehouseCode using keyno 0 * All records *
<IMC_WarehouseCode> First Read Seek sts=-1 key='', len=0, keyno=1
<fh=IMC_WarehouseCode> PVK_read returns buffer= iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer= iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer= iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer= iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer=000000MAIN WAREHOUSE TEST 123 TEST ST LOS ANGELES, CA 11223 ŠŠ iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer=ÐÏÐÏ ŠŠ iRsz='408'
<fh=IMC_WarehouseCode> PVK_read returns buffer= iRsz='-4'
ISAMCloseTable: Closing table IMC_WarehouseCode - 6 file reads, 0 re-reads, 0 writes, 0 removes
ISAMClose
Driver version: 4.21.1000
ISAMOpen: UserID='***', length=3
------------------------------
SELECT * FROM IMC_WarehouseCode

GetAccessibleTables:<table=IMC_WarehouseCode> Open catalog(s) \\**********\MAS90 , available 0 table(s)
ISAMClose: <12> S0000 S0000 [ProvideX][ODBC Driver][FILEIO]Table is not accessible


Any ideas?

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top