473,749 Members | 2,464 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Difference between Access and SQL Server

I have the following query in Access:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id AS
interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM (AllergyDrugPer mutation AS a INNER JOIN alr_category_dr ug_map AS b ON
a.interest_elem ent_id = b.drug_id) INNER JOIN alr_category_dr ug_map AS c ON
a.allergy_eleme nt_id = c.drug_id

and all is well!

When I create the same query in SQL sever (using the desinger), I get:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id AS
interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM dbo.AllergyDrug Permutation a INNER JOIN
dbo.alr_categor y_drug_map b ON a.interest_elem ent_id =
b.drug_id INNER JOIN
dbo.alr_categor y_drug_map c ON a.allergy_eleme nt_id =
c.drug_id

The only structural difference I see here is that SQL removed the ( and )
from around the first join and created the double join.
When I run this query I get stuck in a loop and eventually the sever will
time out. If I only have the first join there is no time out issues but of
course the result is not what I desire.

Can someone help me out here and tell me what is wrong with the statement
used in SQL?

Thank you in advance,
Eric
Jul 20 '05 #1
3 2217
I think I found the problem. AllergyDrugPerm utation is a "view." If I
create a table the has the same data as that in the view I don't get the
time out error.
So the question becomes, why does this fail with view?
Thanks
Eric

"Beringer" <bo*********@in valid.com> wrote in message
news:mbSdd.5630 8$kz3.48760@fed 1read02...
I have the following query in Access:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id AS
interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM (AllergyDrugPer mutation AS a INNER JOIN alr_category_dr ug_map AS b ON
a.interest_elem ent_id = b.drug_id) INNER JOIN alr_category_dr ug_map AS c
ON a.allergy_eleme nt_id = c.drug_id

and all is well!

When I create the same query in SQL sever (using the desinger), I get:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id
AS interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM dbo.AllergyDrug Permutation a INNER JOIN
dbo.alr_categor y_drug_map b ON a.interest_elem ent_id
= b.drug_id INNER JOIN
dbo.alr_categor y_drug_map c ON a.allergy_eleme nt_id =
c.drug_id

The only structural difference I see here is that SQL removed the ( and )
from around the first join and created the double join.
When I run this query I get stuck in a loop and eventually the sever will
time out. If I only have the first join there is no time out issues but
of course the result is not what I desire.

Can someone help me out here and tell me what is wrong with the statement
used in SQL?

Thank you in advance,
Eric

Jul 20 '05 #2
Did you get any error message when the query timeout occured?
Jul 20 '05 #3
Hi

You would need to post DDL and example data (as insert statements) that
recreates the problem
http://www.aspfaq.com/etiquette.asp?id=5006

If you posted the access query (from the access designer) into query
analyser do you still have a problem?

John

"Beringer" <bo*********@in valid.com> wrote in message
news:1mSdd.5630 9$kz3.53477@fed 1read02...
I think I found the problem. AllergyDrugPerm utation is a "view." If I
create a table the has the same data as that in the view I don't get the
time out error.
So the question becomes, why does this fail with view?
Thanks
Eric

"Beringer" <bo*********@in valid.com> wrote in message
news:mbSdd.5630 8$kz3.48760@fed 1read02...
I have the following query in Access:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id AS
interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM (AllergyDrugPer mutation AS a INNER JOIN alr_category_dr ug_map AS b ON a.interest_elem ent_id = b.drug_id) INNER JOIN alr_category_dr ug_map AS c
ON a.allergy_eleme nt_id = c.drug_id

and all is well!

When I create the same query in SQL sever (using the desinger), I get:

SELECT a.interest_pare nt_id, a.interest_elem ent_id, b.alr_category_ id AS interest_catego ry_id, a.allergy_paren t_id, a.allergy_eleme nt_id,
c.alr_category_ id AS allergy_categor y_id
FROM dbo.AllergyDrug Permutation a INNER JOIN
dbo.alr_categor y_drug_map b ON a.interest_elem ent_id = b.drug_id INNER JOIN
dbo.alr_categor y_drug_map c ON a.allergy_eleme nt_id = c.drug_id

The only structural difference I see here is that SQL removed the ( and ) from around the first join and created the double join.
When I run this query I get stuck in a loop and eventually the sever will time out. If I only have the first join there is no time out issues but
of course the result is not what I desire.

Can someone help me out here and tell me what is wrong with the statement used in SQL?

Thank you in advance,
Eric


Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2012
by: Glen Scott | last post by:
Hi, I'm writing an ASP app that administers an ISA server remotely. The fact that it's an ISA server isn't my problem I believe. My question? What is the security difference between disabling anonymous access and using account X from the web client, versus allowing anonymous access but using account X as the account that runs the application? When I configure my web application to allow anonymous access, but set the anonymous process...
2
9907
by: bdwise | last post by:
What is the difference between a Panel and a <div> tag with runat="server"? It seems that I can add child controls to either one in a code-behind and they both render to a <div> anyway at runtime. What is the difference between a Placeholder and a Div, other than a Placeholder does not render at runtime? Thanks.
8
2929
by: James | last post by:
Can someone explain the fundamental difference between creating a "multi user" version of an Access DB and creating a client-server Access DB? ie why can't all the users on my network just click on database.mdb and share the same database? why would I want to create a separate client/server architecture?
12
3249
by: Eric Layman | last post by:
Hi, What's the difference between a normal web element: <input type="text" id="txtname" name="txtname" runat="server"> vs webcontrol text box: <asp:Textbox id="username" Columns="10" runat="server"> </asp:TextBox>
1
19846
by: bharathreddy | last post by:
This Article gives an introduction to VSTS Team Foundation & fundamental difference between Visual Source Safe (VSS) and VSTS Team Foundation. Team Foundation is a set of tools and technologies that enable a team to collaborate and coordinate a project (software or non software projects). The team collaboration is achieved by several tools and features available as part of "Team Foundation". Team Foundation Server The Team...
0
8832
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9566
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9388
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9333
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8256
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6800
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6078
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3319
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2791
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.