Solved

Problem selecting custom OLEDB connection string file in recordset (query) when there are multiple database connections.

Posted on 2004-10-19
6
190 Views
Last Modified: 2010-04-25
I created a group of pages stored in a subfolder (Events1) that use an OLEDB custom connection string connecting to a .mdb Access file (db1.mdb). The 'connConnection1' file created by 'define' is stored in the Connections folder. I then started to create another group of pages in a subfolder (Events2) with a new Access .mdb database.  I then created the a second login page in the Events2 folder. With the login page open in the editor I then defined a new customer connection string, 'connConnection2' connecting to db2.mdb, also stored in the Connections folder.  I tested it and it works. When I opened each of the new pages in the second group of pages in the Events2 folder, they all have the 'connConnection1' connection and NOT the 'connConnection2'. If I select the 'connConnection1' entry and click on the '-' icon on the Application > Database tab, the first, 'connConnection1' file is deleted. If I click on the '+' icon and create a new database connection, it has to be a different name. I have NOT been able to locate any help on how to 'change'  the connection from 'connConnection1' or 'add' the 'connConnection2' connection. If I try to add a 'Recordset (Query)' from the Server Behavors tab in the Application panel I'm unable to select another connection - only the first one is displayed.

Why? Where is the database connection file link stored? I've looked at the code and it isn't there! Am I wrong to assume that I can have 2 (or more) OLEDB (NON-DSN) database definitions?
0
Comment
Question by:jimbthom
  • 3
  • 3
6 Comments
 
LVL 10

Expert Comment

by:rockmansattic
Comment Utility
yes, you can have more than one connection.  
Just to be clear,
in the applications tab, under databses, you have two connections. conn..1 and con..2
you also have two folders events1 and events2 with files in them.
you can only 'see' the conn..1 form all files?


Also, after rereading you question, I think you 'may' not understand DW way of connections (sorry if I am wrong)

when you setup the two connections, they should be visable ( on application tab)  from all php.asp... pages in your site.  This does NOt mean that that page is connected.
You only need to setup the connection once, then setup the other one once.

now, when you ask DW to talk to the database, you should be given the option of which connection you want to use (becasue you know which  database each connection is conneced to)

Let me know if I am way off base.

Rockman
0
 

Author Comment

by:jimbthom
Comment Utility
Thanks for your help. To clarify, on the Database tab of the Application panel only ONE connection (conn..1 or conn..2) is displayed, depending upon the page oppened in the edit window. This is not just in the 'Recordset (Query)' behavior. You may have given a clue. I didn't mention that I am working on .asp pages, not PHP. Any idea where the information on connections available is maintained in DW for newly oppened pages? Because, if I create a new page (right click the mouse), and then open the page created in this manner, it only shows connection conn..1 in the Database tab of the Application panel. I would have assumed that it would display any pages in the Connections folder - and it does not! Right now there are 4 connection .asp files in the Connections folder.

Thonks Rockman.
0
 
LVL 10

Accepted Solution

by:
rockmansattic earned 250 total points
Comment Utility
Ill look into it after lunch...

one quick thing.  recreate site cache.

site>>adv>>recreate.

See if that helps
rockman
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 

Author Comment

by:jimbthom
Comment Utility
I recreated the site cache. Didn't make a difference. I closed DW and restarted it. It starts with no connections shown in the Database panel (and grayed). If I switch to another task (the IE window where I'm updating this comment) and then switch back to DW, the 'conn..1' connection is then displayed (grayed). I removed the other two conn files so only 'conn..1' and 'conn..2' are in the Connections folder. If I open a new document (page)using the Files > New > Dynamic page > ASP JavaScript > Create, the new unamed file opens in the edit window AND the newest connection ('conn..2)  is displayed in the Database panel - and it is NOT grayed. I can then save the page (say as test1.asp). I can then open it and the 'conn..2' connection remains displayed - but ONLY the 'conn..2' and not 'conn..1'! If I then create a new page using the 'right-click' mouse button > New File, it creates the file and I then name it test2.asp, when I open it, the Database panel will switch from from 'conn..2' to 'conn..1'.

I am running ver 7.01.

I have another issue which I have searched every help database, forum, Macromedia site, etc., without even finding any similar problem. That problem (see http://www.experts-exchange.com/Web/WebDevSoftware/DreamWeaver/Q_21164325.html - the File panel view keeps swithing from Testing Server back to Remote View as I work) still remains unresolved. What's more, it appears that this occurs to be unique to my PC. And it never happened before I upgraded to 2004 MX. Possably the problem lies there. I started working on a project for a teacher (and my wife is a teacher) so I purchased (and registered) an Educational Version Suite MX. When I finished that project I decided that DW was MUCH better than FrontPage, which I had been using, so I purchased a non-EV version upgrade. I never created a dynamic page with the EV version so I don't know if the problem would occur with the EV version.

When I updated, the EV version wasn't removed. (I can't remember if I was prompted or not, but it still is on my system, in any case.) Possibly both these issues (and maybe more that I haven't run accross yet) are related to the previous EV, which is still on my system.

I really do appreciate your help. Thanks,

Jim
0
 

Author Comment

by:jimbthom
Comment Utility
I may have discovered the reason this is happening. I originally started developing the site in html code. I later decided to use mostly APS JavaScript, but I inadvently setup the site management for the testing server as VBScript. When I discovered that I had setup the testing server incorrectly as APS VBScript and all my .asp files have VBScript code instead of JavaScript code. I changed the testing server site management to JavaScript. This appears to have fixed the problem. Now what I need to know is if there is any way to convert the 'site' (i.e. multiple .asp files) from VBScript to JavaScript? I haven't been unable to find any extensions or help on the subject.

Jim
0
 
LVL 10

Expert Comment

by:rockmansattic
Comment Utility
glad you got it
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

I still run into .cgi files every now and then. In some instances, I actually prefer the simplicity of a .cgi script to other options. Since I use DreamWeaver extensively, what I needed was a way to open .cgi scripts in Dreamweaver. And I wanted to …
Adobe Dreamweaver CS5 is a WYSIWYG web page editor that has advanced HTML, CSS, and Javascript rendering functionality and is probably the most well-known HTML editor available. Much of Dreamweaver's appeal centers around the Design View interfac…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now