473,416 Members | 1,498 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,416 software developers and data experts.

I've never seen A97 combo-box wizard fail on a valid query until today...

MLH
I invoked the combo-box wizard today, telling it to use a 4-table
union query as a row-source for the combo-box it was assisting
me in building. The error I got was without number and stated,
"Data cannot be retrieved from the source you have selected.
You must select a different table or query to continue in the wizard."
just after I chose the query named
qryAuthsOwnersAddnlOwnersLienholders4OneCar.

Have any of you ever seen that error message in A97 before?
I was able to successfully build the combo-box manually. Each
time I tried to use the query to build it, I failed.

The query runs fine, returning the desired records anytime its
launched. And, the manually constructed combo-box works
fine.

Here is the SQL for the union query...
SELECT [AddnlOwnrFName] & " " & [AddnlOwnrLName] & " " &
[AddnlOwnrAddr] & " " & [AddnlOwnrCity] & ", " & [AddnlOwnrState] & "
" & [AddnlOwnrZip] & " " & "(" & [AddnlOwnrCounty] & " county) " &
Format$([AddnlOwnrPhone],"(@@@) @@@-@@@@") & " " &
IIf([Corporation]=True,"(corporation)","(person)") AS Item,
tblVehicleJobs.VehicleJobID, "X" AS OLAX, tblAddnlOwnrs.AddnlOwnrID AS
RecID
FROM tblVehicleJobs INNER JOIN tblAddnlOwnrs ON
tblVehicleJobs.VehicleJobID = tblAddnlOwnrs.VehicleJobID
WHERE tblVehicleJobs.VehicleJobID=GetCurrentVehicleJobID ();

UNION SELECT [LienHolderName] & " " & [LienHolderAddr] & " " &
[LienHolderCity] & ", " & [LienHolderState] & " " & [LienHolderZip] &
" " & "(" & [LHCounty] & " county) " &
Format$([LienHolderPhone],"(@@@) @@@-@@@@") & " (corporation)" AS
Item, tblVehicleJobs.VehicleJobID, "L" AS OLAX,
tblLienHolders.LienHolderID AS RecID
FROM tblVehicleJobs INNER JOIN tblLienHolders ON
tblVehicleJobs.VehicleJobID = tblLienHolders.VehicleJobID
WHERE tblVehicleJobs.VehicleJobID=GetCurrentVehicleJobID ();

UNION SELECT [OwnerFName] & " " & [OwnerLName] & " " & [OwnerAddr] &
" " & [OwnerCity] & ", " & [OwnerState] & " " & [OwnerZip] & " " &
"(" & [OwnerCounty] & " county) " & Format$([OwnerPhone],"(@@@)
@@@-@@@@") & " (corporation)" AS Item, tblVehicleJobs.VehicleJobID,
"O" AS OLAX, tblOwners.OwnerID AS RecID
FROM tblVehicleJobs INNER JOIN tblOwners ON tblVehicleJobs.OwnerID =
tblOwners.OwnerID
WHERE tblVehicleJobs.VehicleJobID=GetCurrentVehicleJobID ();

UNION SELECT [AuthCompany] & " " & [AuthAddr] & " " & [AuthCity] & ",
" & [AuthState] & " " & [AuthZip] & " " & "(" &
Format$([AuthPhone],"(@@@) @@@-@@@@") AS Item,
tblVehicleJobs.VehicleJobID, "A" AS OLAX, tblAuth.AuthID AS RecID
FROM tblVehicleJobs INNER JOIN tblAuth ON tblVehicleJobs.AuthID =
tblAuth.AuthID
WHERE tblVehicleJobs.VehicleJobID=GetCurrentVehicleJobID ();

Dec 18 '05 #1
2 1843
MLH
Oops. I had a typo in the 2nd paragraph of the OP...

Last line should-a-read... Each time I tried to use the wizard to
build it, I failed.
Dec 18 '05 #2
MLH wrote:
I invoked the combo-box wizard today, telling it to use a 4-table
union query as a row-source for the combo-box it was assisting
me in building. The error I got was without number and stated,
"Data cannot be retrieved from the source you have selected.
You must select a different table or query to continue in the wizard."
just after I chose the query named
qryAuthsOwnersAddnlOwnersLienholders4OneCar.

Have any of you ever seen that error message in A97 before?
I was able to successfully build the combo-box manually. Each
time I tried to use the query to build it, I failed.


I recall it when my SQL in the combo row source was too long. That is,
when I made the SQL actually the row source and not a named query.

Two things I can suggest looking at:

First is if you are putting the name of the query in the row source, ie,
building the query via the Access query builder, saving it as
qryAuthsOwnersAddnlOwnersLienholders4OneCar and then, in the row source
property box, selecting qryAuthsOwnersAddnlOwnersLienholders4OneCar from
a list of tables/queries.

I wonder if the name is too long? I don't think it would be, but try
saving it as "Test" or something short and see if that helps. This is a
guess.

The second thing is if you are actually putting the SQL in the combo
box. In other words, either building the
qryAuthsOwnersAddnlOwnersLienholders4OneCar query in the query builder
and copy/pasting the actual SQL into the row source box OR clicking the
builder button and developing the query from scratch so that there's
"Select blah blah, etc" showing in the row source property rather than
the name of the query.

In this case, it could well be that your SQL is too long (what's
happened to me in the past) for the combo row source property. There's
a limit on the number of characters for the SQL statement in a row
source (I can't recall the character limit). If this is the case,
you'll need to save your sql as a saved query and point the row source
to that query. Again, my posit in the first case is a guess if you run
into the same difficulty.

--
Tim http://www.ucs.mun.ca/~tmarshal/
^o<
/#) "Burp-beep, burp-beep, burp-beep?" - Quaker Jake
/^^ "Whatcha doin?" - Ditto "TIM-MAY!!" - Me
Dec 18 '05 #3

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

Similar topics

5
by: Harry Haller | last post by:
<select name="cboPlaces" id="cboPlaces"> <option value="3">Countryside</option> <option value="4">Forest</option> <option value="5">Mountain</option> <option value="6">Desert</option> <option...
1
by: Tina McGibben | last post by:
I basically have a form with a subform with two combo boxes on the main form which filter the subform. The code below works except I cant seem to get it to show all the worksheets when there is...
2
by: Al | last post by:
hi,I am using asp.net(vb) I am trying to create 3 combo boxes which are dependable on each other. when comb1 is selected, it shows the comb2 data based on the selection in combo1 and when combo2...
1
by: Alejandro González | last post by:
Hi I have a combobox binded to a Datatable something like combo.DataSource = dt.DefaultView; combo.DisplayMember = "descField"; combo.ValueMember = "valueField"; it works fine.
2
by: G .Net | last post by:
Hi Is there a way to prevent the combo displaying its list of items when the "combo arrow" is clicked? The problem I'm trying to resolve is that depending on a Boolean value, which is set...
8
by: AA Arens | last post by:
Hi I do have a products table and products-parts table in my Access 2003 database and log all services into a form. I do have at least the following two combo boxes on my form: - Choose...
3
by: John | last post by:
AC2007 I changed my combo's row source and then the autocomplete stopped working. The combo is two columns, bound to the first. First column is primary key (ID). Second column is a...
0
by: Jeff | last post by:
I don't remember this being that hard. Or maybe it's just early senility. On a simple bound continuous form I have a combo for filtering the form by customer. The form record source is a sql...
4
by: User | last post by:
Hi people, Excuse if my question is silly, but... i have 2 combo boxes in my project they are binded to fields from same table... one is binded do Code field and another to Description field...
0
Cathode Follower
by: Cathode Follower | last post by:
When you populate a combo you load it with data that normally comes in the form of a code and a description - but the combo is only interested in the description. By creating a class derived from a...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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...
0
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...
0
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,...
0
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...
0
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...

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.