I've got two problems. One is that I'm running a (bad) query that causes the ODBC service to hang during the query attempt. I have to repeatedly try to stop the service and once it finally times out, I can restart it.

In a nutshell, I have inherited a database full of relationships (which is good), but poorly designed. All I've done is add a new table to the query and a new field to search on. Here's the query:

<CFQUERY NAME="readesi" DATASOURCE="esidb1">
SELECT DISTINCT tblmasterclients.ClientName, AliasName, AlphaPrefix, SiteID, Infinity, AuthCode, POBox, POBoxCombo, tblmasterclients.Comments, DID,
SVCType, tblmasterclients.AcctStatus, PreparedDate, URL, TerminationReason, TerminationDesc, billingaddr, billingaddr2, billingstate, billingcity,
billingzip, billingcontact, billingemail, billingphone, billingext, billingfaxnumber, billingcellnumber, leaseid

FROM tblMasterClients, tblbillingaddr, tblterm

where tblmasterclients.clientname = "tblbillingaddr.Client Name"
and tblmasterclients.clientname = tblterm.clientname
and tblterm.leaseid = tblbilling.leaseid
and tblmasterclients.acctstatus = 'A'
OR tblmasterclients.acctstatus = 'ACT'

ORDER BY tblmasterclients.clientname
</CFQUERY>

Note: leaseid field and anything related to tblterm is new part I'm adding.

Thanks for any help!
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to