473,666 Members | 2,114 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Can a pass-through query to create a table?

Hello
I need to get data from 4 Oracle tables and combine them into a
temporary table in my application. I get data using a pass-through
query dynamically created in code:
mySQL = "SELECT SID_SCREENING_T ASKS_QUESTIONS. TASK_ID,
mySQL = mySQL & "SID_SCREENING_ TASKS_QUESTIONS .ID,
mySQL = mySQL & "SID_SCREENING_ QUESTIONS.TITLE , "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.Points "
mySQL = mySQL & "from SID_SCREENING_T ASKS_QUESTIONS,
SID_SCREENING_Q UESTIONS, "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T "
mySQL = mySQL & "WHERE
SID_SCREENING_T ASKS_QUESTIONS. ID=SID_SCREENIN G_QUESTIONS.ID and "
mySQL = mySQL & "SID_SCREENING_ TASKS_QUESTIONS .ID=SID_SCREENI NG_QUESTION_STU DENT.ID(+)
and SID_SCREENING_Q UESTIONS.DELETE D IS NULL AND "
mySQL = mySQL & "(SID_SCREENING _QUESTION_STUDE NT.STUDENT_CODE IS NULL
OR "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.STUDENT_CODE= " &
Me![txtStuCode] & ");"
If IsLive = True Then
Set myQuery = "qryScreening_l ive"
Else
Set myQuery = "qryScreening_t est"
End If
myQuery.SQL = mySQL
Set myRSet = myQuery.OpenRec ordset
When I have this recordset, I'll copy the data into a predefined table
looping through the recordset.
A question: can I create the above query so that it creates a table
with the data returned?
Thank you.
Galina
Nov 13 '05 #1
2 10657
Save the pass-through query, then create a MakeTable query based on the
saved pass-through query.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

"Galina" <ga****@mail.ru > wrote in message
news:ec******** *************** **@posting.goog le.com...
Hello
I need to get data from 4 Oracle tables and combine them into a
temporary table in my application. I get data using a pass-through
query dynamically created in code:
mySQL = "SELECT SID_SCREENING_T ASKS_QUESTIONS. TASK_ID,
mySQL = mySQL & "SID_SCREENING_ TASKS_QUESTIONS .ID,
mySQL = mySQL & "SID_SCREENING_ QUESTIONS.TITLE , "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.Points "
mySQL = mySQL & "from SID_SCREENING_T ASKS_QUESTIONS,
SID_SCREENING_Q UESTIONS, "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T "
mySQL = mySQL & "WHERE
SID_SCREENING_T ASKS_QUESTIONS. ID=SID_SCREENIN G_QUESTIONS.ID and "
mySQL = mySQL & "SID_SCREENING_ TASKS_QUESTIONS .ID=SID_SCREENI NG_QUESTION_STU DENT.ID(+) and SID_SCREENING_Q UESTIONS.DELETE D IS NULL AND "
mySQL = mySQL & "(SID_SCREENING _QUESTION_STUDE NT.STUDENT_CODE IS NULL
OR "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.STUDENT_CODE= " &
Me![txtStuCode] & ");"
If IsLive = True Then
Set myQuery = "qryScreening_l ive"
Else
Set myQuery = "qryScreening_t est"
End If
myQuery.SQL = mySQL
Set myRSet = myQuery.OpenRec ordset
When I have this recordset, I'll copy the data into a predefined table
looping through the recordset.
A question: can I create the above query so that it creates a table
with the data returned?
Thank you.
Galina

Nov 13 '05 #2
Interesting... Thank you.
Galina

"Douglas J. Steele" <NOSPAM_djsteel e@NOSPAM_canada .com> wrote in message news:<zP******* *************** @twister01.bloo r.is.net.cable. rogers.com>...
Save the pass-through query, then create a MakeTable query based on the
saved pass-through query.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

"Galina" <ga****@mail.ru > wrote in message
news:ec******** *************** **@posting.goog le.com...
Hello
I need to get data from 4 Oracle tables and combine them into a
temporary table in my application. I get data using a pass-through
query dynamically created in code:
mySQL = "SELECT SID_SCREENING_T ASKS_QUESTIONS. TASK_ID,
mySQL = mySQL & "SID_SCREENING_ TASKS_QUESTIONS .ID,
mySQL = mySQL & "SID_SCREENING_ QUESTIONS.TITLE , "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.Points "
mySQL = mySQL & "from SID_SCREENING_T ASKS_QUESTIONS,
SID_SCREENING_Q UESTIONS, "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T "
mySQL = mySQL & "WHERE
SID_SCREENING_T ASKS_QUESTIONS. ID=SID_SCREENIN G_QUESTIONS.ID and "
mySQL = mySQL &

"SID_SCREENING_ TASKS_QUESTIONS .ID=SID_SCREENI NG_QUESTION_STU DENT.ID(+)
and SID_SCREENING_Q UESTIONS.DELETE D IS NULL AND "
mySQL = mySQL & "(SID_SCREENING _QUESTION_STUDE NT.STUDENT_CODE IS NULL
OR "
mySQL = mySQL & "SID_SCREENING_ QUESTION_STUDEN T.STUDENT_CODE= " &
Me![txtStuCode] & ");"
If IsLive = True Then
Set myQuery = "qryScreening_l ive"
Else
Set myQuery = "qryScreening_t est"
End If
myQuery.SQL = mySQL
Set myRSet = myQuery.OpenRec ordset
When I have this recordset, I'll copy the data into a predefined table
looping through the recordset.
A question: can I create the above query so that it creates a table
with the data returned?
Thank you.
Galina

Nov 13 '05 #3

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

Similar topics

5
3132
by: Seeker | last post by:
Newbie question here... I have a form with some radio buttons. To verify that at least one of the buttons was chosen I use the following code ("f" is my form object) : var btnChosen; for (count = 0; count <= 1; count++) { if (eval(f.RadioButtons.checked)) { btnChosen = true; }
110
9899
by: Mr A | last post by:
Hi! I've been thinking about passing parameteras using references instead of pointers in order to emphasize that the parameter must be an object. Exemple: void func(Objec& object); //object must be an object instead of
0
1331
by: uli2003wien | last post by:
Dear group, PASS (SQL-Server user group) is about to start founding a branch in Vienna. I went to SQLCON and met some guys from the German PASS group and decided to become a member of PASS, decided to look for other individuals to take part in an Austrian branch of PASS based in Vienna, so whoever is interested may take a look at http://www.sqlpass.de/Default.aspx?tabid=191 in order to get to contact me to get things going....
9
12869
by: Jay Douglas | last post by:
Hello, I am needing to pass a class object (this) by reference to a method in a different class. When I do the following code I get the error (Cannot pass '<this>' as a ref or out argument because it is read-only) .. Is there any way to make <this> not read-only? I have simplified the following code. There is a Task class and a Data Class. I am trying to pass the task class by ref to the data class. public class Task {
4
3400
by: z_learning_tester | last post by:
I'm reading the MS press C# book and there seems to be a contradiction. Please tell me which one is correct, 1 or 2. Thanks! Jeff 1. First it gives the code below saying that it prints 0 then 42. They say that 42 is printed the second time since the value was wrapped in a class and therefore became passed by reference. (sorry for any typos I am a newbie here ;-)
14
20389
by: Abhi | last post by:
I wrote a function foo(int arr) and its prototype is declared as foo(int arr); I modify the values of the array in the function and the values are getting modified in the main array which is passed also. I understand that this way of passing the array is by value and if the prototype is declared as foo(int *), it is by reference in which case the value if modified in the function will get reflected in the main function as well. I dont...
4
9111
by: kinaxx | last post by:
Hello, now I'm learning progamming language in university. but i have some question. in textbook. says there are four passing Mechanism 1) pass by value (inother words : call by value) 2) pass by reference (inother words: call by reference) 3) pass by value-result <- i have question this subject . 4) pass by name
6
2708
by: lisp9000 | last post by:
I've read that C allows two ways to pass information between functions: o Pass by Value o Pass by Reference I was talking to some C programmers and they told me there is no such thing as pass by reference in C since you are just passing an address (or a pointer value address I guess?). So I was wondering is this correct?
15
2014
by: ramif | last post by:
Does call by reference principle apply to pointers?? Is there a way to pass pointers (by reference) to functions? Here is my code: #include <stdio.h> #include <stdlib.h>
12
11076
by: raylopez99 | last post by:
Keywords: scope resolution, passing classes between parent and child forms, parameter constructor method, normal constructor, default constructor, forward reference, sharing classes between forms. Here is a newbie mistake that I found myself doing (as a newbie), and that even a master programmer, the guru of this forum, Jon Skeet, missed! (He knows this I'm sure, but just didn't think this was my problem; LOL, I am needling him) If...
0
8356
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
8866
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...
1
8550
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
8639
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7385
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
6192
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
4366
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2769
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
2011
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.