M
mark kubicki
(this is part a follow-up question to a previous chat... see below...)
I have 2 tables, one of which has only 1 record, the other having several
-the 1 record table has 24 fields
-the multi-record has a whopping 83 fields
-there are no linked fields between the two
the suggestion was made that I could create a query from these 2 tables for
use as data source in a report.
---> the problem that I'm having is doing exactly that; I continually run
into a wall that tells me I need to have a relationship between the two ?!?!
I've tried creating a stand alone query, and also an SQL query in the the
report as its data source: same problem both places
lost,
(thanks in advance)
-mark
----------------------------------------------------------------------
What is the structure of tblPrintOptions? Is it a one record table with
multiple fields? (yes)
If so, you can add the table to your query with NO join. Then each row
produced
would have all the options in the row and you could build your query with
SELECT SomeField,
, SomeOtherField
, IIF(tblPrintOptions.[Abbreviate Description],
Left(tblData.[Description],50))
as Description
, IIF(tblPrintOptions.[Include Location], "Location:" &
tblData.[Location],Null)
as Location
, IIF(tblPrintOptions.[Include Notes], "Notes:" & tblData.[Notes]) as Notes
, ...
FROM tblData, tblPrintOptions
This should be faster than doing all those lookups.
I have 2 tables, one of which has only 1 record, the other having several
-the 1 record table has 24 fields
-the multi-record has a whopping 83 fields
-there are no linked fields between the two
the suggestion was made that I could create a query from these 2 tables for
use as data source in a report.
---> the problem that I'm having is doing exactly that; I continually run
into a wall that tells me I need to have a relationship between the two ?!?!
I've tried creating a stand alone query, and also an SQL query in the the
report as its data source: same problem both places
lost,
(thanks in advance)
-mark
----------------------------------------------------------------------
What is the structure of tblPrintOptions? Is it a one record table with
multiple fields? (yes)
If so, you can add the table to your query with NO join. Then each row
produced
would have all the options in the row and you could build your query with
SELECT SomeField,
, SomeOtherField
, IIF(tblPrintOptions.[Abbreviate Description],
Left(tblData.[Description],50))
as Description
, IIF(tblPrintOptions.[Include Location], "Location:" &
tblData.[Location],Null)
as Location
, IIF(tblPrintOptions.[Include Notes], "Notes:" & tblData.[Notes]) as Notes
, ...
FROM tblData, tblPrintOptions
This should be faster than doing all those lookups.