"blanks" in forms

B

Ben Blair

Alright, let me explain what I'm doing. I have a form that automatically
becomes a table. The form has maybe a dozen different spaces. The table that
gets created is acting like a filter for another table, which will eventually
turn into a third table that has been filtered.

My question is this: I established relationships between all of the fields
in the form and the individual tables (i.e. account to account and dept to
dept). I need to know if there is a symbol or something to insert in the
fields of the form that I want left blank, but that have corresponding data
in the other table. For example:

Form Table 1
Name: Smith Name: Smith
Date: Date: July-05
Acct: 854389 Acct: 854389

So basically I just need to know if there is a code to put in that will act
like a filler so I can see everything in that column. Sorry if it's not
clear, please ask if you have questions.
 
R

Rick B

Huh?

You don't need to make a table to do any of this.

In your query, just use the controls in this unbound form as criteria.

Use "Like & "*"" to allow for blanks.

For example, in your query, put the following in your criteria...

Like Forms![MySearchFormName]![MySearchFieldName] & "*"
 
B

Ben Blair

Unfortunatley, my hands are tied about the way the database is designed. All
I have to do is design these certain processes to act as form filters that
eventually create reports. So essentially I agree that the way I'm doing it
is not the best, but I have to stick with what they give me... so is that
bottom line all I have to enter into the form? Thanks again.
Ben

Rick B said:
Huh?

You don't need to make a table to do any of this.

In your query, just use the controls in this unbound form as criteria.

Use "Like & "*"" to allow for blanks.

For example, in your query, put the following in your criteria...

Like Forms![MySearchFormName]![MySearchFieldName] & "*"




--
Rick B



Ben Blair said:
Alright, let me explain what I'm doing. I have a form that automatically
becomes a table. The form has maybe a dozen different spaces. The table that
gets created is acting like a filter for another table, which will eventually
turn into a third table that has been filtered.

My question is this: I established relationships between all of the fields
in the form and the individual tables (i.e. account to account and dept to
dept). I need to know if there is a symbol or something to insert in the
fields of the form that I want left blank, but that have corresponding data
in the other table. For example:

Form Table 1
Name: Smith Name: Smith
Date: Date: July-05
Acct: 854389 Acct: 854389

So basically I just need to know if there is a code to put in that will act
like a filler so I can see everything in that column. Sorry if it's not
clear, please ask if you have questions.
 
R

Rick B

If I understand, you are trying to enter criteria in a form and then use
that criteria to select records in a query.

If that is true, then your sentence about creating a table from the form has
no place. You are coming up with some complex way to perform a very simple
task. (And I have no idea how you are handling it. The method you mention
makes no sense to me.)

To filter query result based on entries in a form, you simply reference the
controls on the form in your query in the criteria section. In English, you
are saying to Access...

Give me all records where the entry in "Name" is the same as what my user
typed on my "parameter" form. AND also limit the results to where the
entries in "State" are equal to what my user typed in the "state" field of
my "parameter" form. AND If I leave any field on my "parameter" form blank,
disregard that field when pulling the results.

If that is indeed what you are doing, then you simply use the controls in
your query as stated.

Using your current method of making entries, creating a table, and then
using that table to filter your query does not make sense, and I would have
no idea how to disregard blanks in that case, because I have no idea what
the query is doing to match up the records.

For more information on how to filter a query based on entries in an unbound
form, read the hundreds of previous posts on the topic. If you can't modify
the query, print some of these posts out and take them to the person who can
modify the database. OR ASK THEM how to do what you are trying to do.

To search for previous posts go to www.google.com, click the "groups"
option, and enter a search string like the following...

microsoft.public.access parameter form query


--
Rick B



Ben Blair said:
Unfortunatley, my hands are tied about the way the database is designed. All
I have to do is design these certain processes to act as form filters that
eventually create reports. So essentially I agree that the way I'm doing it
is not the best, but I have to stick with what they give me... so is that
bottom line all I have to enter into the form? Thanks again.
Ben

Rick B said:
Huh?

You don't need to make a table to do any of this.

In your query, just use the controls in this unbound form as criteria.

Use "Like & "*"" to allow for blanks.

For example, in your query, put the following in your criteria...

Like Forms![MySearchFormName]![MySearchFieldName] & "*"




--
Rick B



Ben Blair said:
Alright, let me explain what I'm doing. I have a form that automatically
becomes a table. The form has maybe a dozen different spaces. The
table
that
gets created is acting like a filter for another table, which will eventually
turn into a third table that has been filtered.

My question is this: I established relationships between all of the fields
in the form and the individual tables (i.e. account to account and dept to
dept). I need to know if there is a symbol or something to insert in the
fields of the form that I want left blank, but that have corresponding data
in the other table. For example:

Form Table 1
Name: Smith Name: Smith
Date: Date: July-05
Acct: 854389 Acct: 854389

So basically I just need to know if there is a code to put in that
will
act
like a filler so I can see everything in that column. Sorry if it's not
clear, please ask if you have questions.
 
R

Rick B

Also, in rereading your post, it sounds like you end up with three tables
before it is all said and done. Your design is badly flawed. Creating a
report from a query should almost never involve creating a new table.
Either use the form to filter your query, or use the data from that form in
a filter on your report. In either case, if you can add a report and if you
can add a query, then you can get this to work. You say you have no control
over the structure - you don't need it.

--
Rick B



Ben Blair said:
Unfortunatley, my hands are tied about the way the database is designed. All
I have to do is design these certain processes to act as form filters that
eventually create reports. So essentially I agree that the way I'm doing it
is not the best, but I have to stick with what they give me... so is that
bottom line all I have to enter into the form? Thanks again.
Ben

Rick B said:
Huh?

You don't need to make a table to do any of this.

In your query, just use the controls in this unbound form as criteria.

Use "Like & "*"" to allow for blanks.

For example, in your query, put the following in your criteria...

Like Forms![MySearchFormName]![MySearchFieldName] & "*"




--
Rick B



Ben Blair said:
Alright, let me explain what I'm doing. I have a form that automatically
becomes a table. The form has maybe a dozen different spaces. The
table
that
gets created is acting like a filter for another table, which will eventually
turn into a third table that has been filtered.

My question is this: I established relationships between all of the fields
in the form and the individual tables (i.e. account to account and dept to
dept). I need to know if there is a symbol or something to insert in the
fields of the form that I want left blank, but that have corresponding data
in the other table. For example:

Form Table 1
Name: Smith Name: Smith
Date: Date: July-05
Acct: 854389 Acct: 854389

So basically I just need to know if there is a code to put in that
will
act
like a filler so I can see everything in that column. Sorry if it's not
clear, please ask if you have questions.
 
Top