ISTech Support Forum
http://www.istechforum.com/YaBB.pl
Evo-ERP and DBA Classic >> Installation >> Windows Server 2003 and DBA
http://www.istechforum.com/YaBB.pl?num=1109281583

Message started by julian on 02/24/05 at 13:46:23

Title: Windows Server 2003 and DBA
Post by julian on 02/24/05 at 13:46:23

I am having trouble running DBA on a new 2003 server.  I've installed it with Pervasive 2000i SP4.  I can get DBA to run fine on multiple machines but I can't seem to make any odbc connections to my DBA data.  Other symptoms of the problem i'm seeing are:

I can't use maintain database.  It gives me this error followed by the filename i'm trying to access.  The lack of a slash between DBA and DEFAULT is not a typo on my part, it's there and it's wrong.

Btrieve Status 11 - The specified filename is invalid Key=[C:\DBAMFGDEFUALT\...

And DBA is not showing up as one of the database choices when I try to add a DSN.

Any help is greatly appreciated!  I have written a bunch of php software that interfaces with DBA and really need to implement it on server 2003.  Thanks!!!

Title: Re: Windows Server 2003 and DBA
Post by julian on 02/24/05 at 13:57:28

Well, I've fixed the maintain database problem with UT-A MDBFXREG per a prior post (sorry, should have found that before posting).  But, I guess my main problem is that I can't make any DSNs to my default company.  DEMODATA is the only database that shows up in pervasive control center.  Again, any help is greatly appreciated.

Title: Re: Windows Server 2003 and DBA
Post by aricon on 02/24/05 at 14:16:25

Create the ODBC connection in Windows ODBC Administrator. Works better.

You need to create a System DSN on the server and point it at your default company and then create one on the client machines that will use it that matches.

Hope that helps.

Title: Re: Windows Server 2003 and DBA
Post by julian on 02/28/05 at 05:19:48

Thanks for the reply, aricon.  The problem is I can't seem to make a System DSN in the odbc administrator.  After choosing the Pervasive ODBC Engine Interface driver I'm presented with a screen to choose the Database Name from a drop down list.  On my windows 2000 machine where it works fine, DBA shows up as one of the choices.  On the Win2k3 machine DBA doesn't show up, and all that shows up is the DEMODATA (which is also the only listed database in pervasive control center, which is wierd).  Thanks again!!!

Title: Re: Windows Server 2003 and DBA
Post by aricon on 02/28/05 at 10:47:31

You have to ADD it on the client machine as well. Not just on the server and until you add it on the client machine you won't see it in the dropdown.

Title: Re: Windows Server 2003 and DBA
Post by julian on 03/03/05 at 08:18:00

Thanks for the help aricon.  I simply forgot how to make a dsn to the dba data since its been about a year and a half since i last did it.  When I originally did it I followed some instructions on a website that since seems to have been taken down.  If anybody wants me to post up a how-to on it I'd be happy to.  I'll also post up the asp code i use to connect and display dba data in a web page... if anybody's interested.  Thanks again for the help.

Title: Re: Windows Server 2003 and DBA
Post by aricon on 03/03/05 at 09:46:22

Julian,

I would be interested in seeing the ASP code. The other part I'm pretty familiar with. ;D

Title: Re: Windows Server 2003 and DBA
Post by Danimal on 03/03/05 at 10:59:25

We have been running parts of DBA over our intranet for a while now, and works great for the most part.

Julian - question for you - does your ASP code handle "space-terminated" binary data?  I found that some fields do not display (or SQL SELECT, etc) properly unless the data is first processed through a transposing function.  Otherwise, some data appears like "???|||" (question marks and daggers).

If not, I would be willing to provide you the ASP functions that I've been using that are necessary to do this, just send me a message.

NOTE:  Client DSN's are not necessary to set up if your Pervasive server is hosting your intranet as well, since ASP is processed server-side.

Title: Re: Windows Server 2003 and DBA
Post by Lynn Pantic on 03/03/05 at 20:33:18

I think there is a lot of interest in linking DBA/Pervasive data to the web.  If anybody who has already developed some of this is willing to share, let me know, I can set up a page on the IS Tech Support web site to post and download files.  

If you have a significant investment in the development and don't want to share for free, we can go there too.

Title: Re: Windows Server 2003 and DBA
Post by Danimal on 03/04/05 at 14:13:38

I would gladly make a contribution toward the advancement of user knowledge of this methodology. ;D  Lynn - look for a message in your inbox in the near future.  I will include a demonstration page to get users familiar with the function operations.

Title: DBA2Web
Post by GasGiant on 03/07/05 at 09:13:42

Wow, and I thought I was the only one would wished DBA would skip Windoze and go straight to a web interface  ::)

Actually, it sounds like we're just talking about reporting (output) to HTML, but that's a great first step.

What say we start some new threads on this in the Programming forum?

Title: Re: Windows Server 2003 and DBA
Post by julian on 03/08/05 at 18:00:15

I've never actually written to the data in the DBA database, but i use the data from DBA and a mysql database to run a serialnumber log.  The ASP code I use to connect to DBA is as follows:



<%
'Betrieve Connetcion
dim DBAConn

set DBAConn = Server.CreateObject("ADODB.Connection")
DBAConn.Open "DSN=DBA", "", ""

'Sales Order Line Items "BKARINVL_B"
dim SOLineItemsRS, RSConString
set SOLineItemsRS = Server.CreateObject("ADODB.RecordSet")
RSConString = "SELECT * FROM " & chr(34) & "BKARINVL_B" & chr(34)
set SOLineItemsRS = DBAConn.Execute(RSConString)

'Sales Order Header "BKARINV_B"
dim SalesOrderRS
set SalesOrder = Server.CreateObject("ADODB.RecordSet")
RSConString = "SELECT * FROM " & chr(34) & "BKARINV_B" & chr(34)
set SalesOrderRS = DBAConn.Execute(RSConString)
%>

<h2>Please choose which line you are shipping against:</h2>
<table border="1" cellpadding="5">
<tr><td><strong>SO#:</strong> </td>
<td><strong>Line#:</strong></td>
<td><strong>Model:</strong></td>
<td><strong>Description:</strong></td>
<td><strong>Customer:</strong></td>
<td><strong>Customer SO#:</strong></td>
<td><strong>Qty:</strong></td>
<td><strong>Shipped:</strong></td>
<td><strong>On BO:</strong></td>
<td><strong>Ship Date:</strong></td></tr>


<%
dim SONum
do while not SalesOrderRS.EOF
if InputSalesOrderNumber = trim(SalesOrderRS("BKAR_INV_CUSORD").VALUE) then
SONum = SalesOrderRS("BKAR_INV_SONUM").VALUE
do while not SOLineItemsRS.EOF
if trim(SONum) = trim(SOLineItemsRS("BKAR_INVL_INVNM").VALUE) then
' make sure the line is not an option or other...
if Instr(SOLineItemsRS("BKAR_INVL_UM_LN[  1]").Value, "C") = 0 and Instr(SOLineItemsRS("BKAR_INVL_UM_LN[  1]").Value, "M") = 0 and Instr(SOLineItemsRS("BKAR_INVL_UM_LN[  1]").Value, "A") = 0 and cint(SOLineItemsRS("BKAR_INVL_OOQTY").Value) <> 0 then
%>
<tr><td><% = SOLineItemsRS("BKAR_INVL_INVNM").Value%></td>
<td><a href="add_sn.asp?so=<%=SONum%>&linenumber=<% = SOLineItemsRS("BKAR_INVL_UM_LN[  1]").Value%>"><% = SOLineItemsRS("BKAR_INVL_UM_LN[  1]").Value%></a></td>
<td><% = SOLineItemsRS("BKAR_INVL_PCODE").Value%></td>
<td><% = SOLineItemsRS("BKAR_INVL_PDESC").Value%></td>
<td><% = SalesOrderRS("BKAR_INV_CUSCOD").Value%></td>
<td><% = SalesOrderRS("BKAR_INV_CUSORD").Value%></td>
<td><% = SOLineItemsRS("BKAR_INVL_OOQTY").Value%></td>
<td><% = SOLineItemsRS("BKAR_INVL_USTD").Value%></td>
<td><% = SOLineItemsRS("BKAR_INVL_UBO").Value%></td>
<td><% = SOLineItemsRS("BKAR_INVL_ESD").Value%></td>
</tr>
<%
end if
end if
SOLineItemsRS.MoveNext
loop
end if
SalesOrderRS.MoveNext
loop

SOLineItemsRS.close
set SOLineItemsRS = Nothing
DBAConn.close
set DBAConn = Nothing
%>
</table>



Pretty basic stuff that shows some info from the sales order files in DBA.  I haven't had any problems with the data showing up incorrectly... but I havent gone that deep into the data files with ASP.  That was some of the first ASP code I ever wrote, so please don't flame me... :P  

Title: Re: Windows Server 2003 and DBA
Post by Danimal on 03/08/05 at 22:30:33


julian wrote:
That was some of the first ASP code I ever wrote, so please don't flame me... :P  

Not bad Julian, everybody's roots have to grow somewhere! ;)  The code that I will be providing is a bit cleaner to work with, but the concepts are the same.  I guess that is the way programming works, finding a more efficient means of obtaining the same output.

A thread has been created in the programming forum continuing this topic.  I am ready to release the demo that I created, just waiting for a good spot to post it for everyone to access... ;D  I hope that you and many others find it beneficial.

ISTech Support Forum » Powered by YaBB 2.1!
YaBB © 2000-2005. All Rights Reserved.