Mikkel
10-09-2008, 10:39 AM
I am trying to create a table of constants using Dlookup (VAT, ExchRate etc)
My problem is in the query design window, when adding the Constants Table, The query does not allow me then to create any new records in the last row unless I create a some kind of relationships.
What relationships are required for the tables and queries for the Constants Table to work? I would have thought None?
Please help!
Thanks,
Mike
Mikkel
10-11-2008, 12:01 AM
Noyone has replied to my question, but I may have found an answer..
I created an outer join to the Tbl_Constants with primary key ConstID in the query window. (No relationship in the table view.) In the parent table, set the default value to 1 for ConstID.
Mike
neileg
10-14-2008, 04:51 AM
I didn't reply because I didn't understand the question. If you're using DLookup to retrieve the value then you don't need to include the table in the query. If the table is in the query, you don't use VLookup.
gemma-the-husky
10-14-2008, 06:42 AM
a constants tabel is normally a single record table, with various system settings. becuase there is only one record you can either
a) do a dlookup to read anything or
b) if necessary, include the table in any query without linking it to other tables, - since as there is only one record you will not get a cartesian join
now if you have a vat rate table with multiple records, then this is not the same thing at all, and in general you would need to do a specific lookup to retrieve the correct row /value from the VAT table
Pat Hartman
10-14-2008, 08:07 AM
b) the join will still be Cartesian so the recordset will not be updateable, the records just won't be duplicated because one side of the join has only a single row.