Date Range Entry

J

jdbit2byte

I am having problems trying to store multiple date entries for a schedule
database.
So far I have a form that a user can select a technician and date and type
in what they are to do for that day. Problem is, often these techs will be
on the same job for 2 weeks or even a month. As the form is now, you can
schedule one or more techs for one day at once, but you can't schedule one or
more for mult days all at once.

Is it possible to declare a date range and schedule given tech for that range?
The table that the form makes records in looks like this.

ScheduleID : TechID : Date : Location
: Comments

([Tech ID] references a Tech Table)

Thanks,
JD
 
J

Jeff Boyce

It sounds like you are saying you'd like to have multiple rows in your
[Schedule] table for a given [TechID], for a given [Location] (?why not a
[LocationID]), for multiple dates (your date range).

By the way, MS Access treats the word "Date" as a reserved word. What YOU
mean by that and what Access means by that may not always be the same. If
you don't want to risk a misunderstanding, consider changing the name of
that field to something more meaningful (and less "reserved") ...
?ScheduledDate?

In Access, it all starts with the data. Forms are convenient ways to
add/edit data, but tables store it.

Since you appear to already have a one-to-many relationship between [TechID]
and [Schedule], you could use a standard Access approach. Create a main
form that displays "Tech" information. Create another form that displays
rows from the [Schedule] table. Rather than using a continuous form, try
"Single Form", but make it tall enough to show many rows. Embed that second
form as a subform within your main form, and remind Access that [TechID] is
the field they share in common.

Now, when you want to show a Tech scheduled for multiple days, add multiple
rows. This approach also gives you the flexibility of "scheduling" a Tech
for Monday - Wednesday - Friday, or ...

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
J

jdbit2byte

Hey Jeff thanks for the reply,

I'm not sure if I was clear so I thought I would try to explain exactly what
I'm trying to do.

I have a schedule form that is using the flxgrd control. So I have an
exellent form that displays the schedule. I also have a form that displays
the list of technicians. Then the user fills out date/job
sight/time/comments, then as they dbl click the tech names it adds it to the
schedule table. They liked this side form so much they want it the other way
around. In other words the form I have can easily put multiple technicians
down on one day, but they would like to put one tech on multiple days etc.

I was thinking of making a date range selector (beggining date and end date)
then have a list of techs. As the tech names are dbl clicked out of the
listbox the schedule table would recieve the entries for each day in the date
range.

So if I put beginning date 1/1/8 (selectable from calandar) and end date
1/4/8

Fill out the rest in text boxes

Job: North Bend Stadium
Time: 8:00 a.m.
Comments: Sight closes at 6:00 p.m.

I could now dbl click the listbox of tech names.
So if I clicked "Bob Doe" (in tbl_tech as TechID: 351)
it would make entries in the tbl_Schedule table as follow:

SchID SchDate TechID JobSight SchTime Comm
1 1/1/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
2 1/2/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
3 1/3/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
4 1/4/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm

If Jeff or anyone has any ideas one what to try let me know plz
My only thought was using arrays but I'm not familiar with them.

Thanks,
JD

Jeff Boyce said:
It sounds like you are saying you'd like to have multiple rows in your
[Schedule] table for a given [TechID], for a given [Location] (?why not a
[LocationID]), for multiple dates (your date range).

By the way, MS Access treats the word "Date" as a reserved word. What YOU
mean by that and what Access means by that may not always be the same. If
you don't want to risk a misunderstanding, consider changing the name of
that field to something more meaningful (and less "reserved") ...
?ScheduledDate?

In Access, it all starts with the data. Forms are convenient ways to
add/edit data, but tables store it.

Since you appear to already have a one-to-many relationship between [TechID]
and [Schedule], you could use a standard Access approach. Create a main
form that displays "Tech" information. Create another form that displays
rows from the [Schedule] table. Rather than using a continuous form, try
"Single Form", but make it tall enough to show many rows. Embed that second
form as a subform within your main form, and remind Access that [TechID] is
the field they share in common.

Now, when you want to show a Tech scheduled for multiple days, add multiple
rows. This approach also gives you the flexibility of "scheduling" a Tech
for Monday - Wednesday - Friday, or ...

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP


jdbit2byte said:
I am having problems trying to store multiple date entries for a schedule
database.
So far I have a form that a user can select a technician and date and type
in what they are to do for that day. Problem is, often these techs will
be
on the same job for 2 weeks or even a month. As the form is now, you can
schedule one or more techs for one day at once, but you can't schedule one
or
more for mult days all at once.

Is it possible to declare a date range and schedule given tech for that
range?
The table that the form makes records in looks like this.

ScheduleID : TechID : Date : Location
: Comments

([Tech ID] references a Tech Table)

Thanks,
JD
 
J

Jeff Boyce

I'll step back, as I have no experience with that control.

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP

jdbit2byte said:
Hey Jeff thanks for the reply,

I'm not sure if I was clear so I thought I would try to explain exactly
what
I'm trying to do.

I have a schedule form that is using the flxgrd control. So I have an
exellent form that displays the schedule. I also have a form that
displays
the list of technicians. Then the user fills out date/job
sight/time/comments, then as they dbl click the tech names it adds it to
the
schedule table. They liked this side form so much they want it the other
way
around. In other words the form I have can easily put multiple
technicians
down on one day, but they would like to put one tech on multiple days etc.

I was thinking of making a date range selector (beggining date and end
date)
then have a list of techs. As the tech names are dbl clicked out of the
listbox the schedule table would recieve the entries for each day in the
date
range.

So if I put beginning date 1/1/8 (selectable from calandar) and end date
1/4/8

Fill out the rest in text boxes

Job: North Bend Stadium
Time: 8:00 a.m.
Comments: Sight closes at 6:00 p.m.

I could now dbl click the listbox of tech names.
So if I clicked "Bob Doe" (in tbl_tech as TechID: 351)
it would make entries in the tbl_Schedule table as follow:

SchID SchDate TechID JobSight SchTime Comm
1 1/1/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
2 1/2/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
3 1/3/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
4 1/4/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm

If Jeff or anyone has any ideas one what to try let me know plz
My only thought was using arrays but I'm not familiar with them.

Thanks,
JD

Jeff Boyce said:
It sounds like you are saying you'd like to have multiple rows in your
[Schedule] table for a given [TechID], for a given [Location] (?why not a
[LocationID]), for multiple dates (your date range).

By the way, MS Access treats the word "Date" as a reserved word. What
YOU
mean by that and what Access means by that may not always be the same.
If
you don't want to risk a misunderstanding, consider changing the name of
that field to something more meaningful (and less "reserved") ...
?ScheduledDate?

In Access, it all starts with the data. Forms are convenient ways to
add/edit data, but tables store it.

Since you appear to already have a one-to-many relationship between
[TechID]
and [Schedule], you could use a standard Access approach. Create a main
form that displays "Tech" information. Create another form that displays
rows from the [Schedule] table. Rather than using a continuous form, try
"Single Form", but make it tall enough to show many rows. Embed that
second
form as a subform within your main form, and remind Access that [TechID]
is
the field they share in common.

Now, when you want to show a Tech scheduled for multiple days, add
multiple
rows. This approach also gives you the flexibility of "scheduling" a
Tech
for Monday - Wednesday - Friday, or ...

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP


jdbit2byte said:
I am having problems trying to store multiple date entries for a
schedule
database.
So far I have a form that a user can select a technician and date and
type
in what they are to do for that day. Problem is, often these techs
will
be
on the same job for 2 weeks or even a month. As the form is now, you
can
schedule one or more techs for one day at once, but you can't schedule
one
or
more for mult days all at once.

Is it possible to declare a date range and schedule given tech for that
range?
The table that the form makes records in looks like this.

ScheduleID : TechID : Date : Location
: Comments

([Tech ID] references a Tech Table)

Thanks,
JD
 
J

jdbit2byte

alright lol, well thx for trying though

JD


Jeff Boyce said:
I'll step back, as I have no experience with that control.

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP

jdbit2byte said:
Hey Jeff thanks for the reply,

I'm not sure if I was clear so I thought I would try to explain exactly
what
I'm trying to do.

I have a schedule form that is using the flxgrd control. So I have an
exellent form that displays the schedule. I also have a form that
displays
the list of technicians. Then the user fills out date/job
sight/time/comments, then as they dbl click the tech names it adds it to
the
schedule table. They liked this side form so much they want it the other
way
around. In other words the form I have can easily put multiple
technicians
down on one day, but they would like to put one tech on multiple days etc.

I was thinking of making a date range selector (beggining date and end
date)
then have a list of techs. As the tech names are dbl clicked out of the
listbox the schedule table would recieve the entries for each day in the
date
range.

So if I put beginning date 1/1/8 (selectable from calandar) and end date
1/4/8

Fill out the rest in text boxes

Job: North Bend Stadium
Time: 8:00 a.m.
Comments: Sight closes at 6:00 p.m.

I could now dbl click the listbox of tech names.
So if I clicked "Bob Doe" (in tbl_tech as TechID: 351)
it would make entries in the tbl_Schedule table as follow:

SchID SchDate TechID JobSight SchTime Comm
1 1/1/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
2 1/2/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
3 1/3/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm
4 1/4/08 351 North Bend.. 8:00am Job Sight
closes at 6:00pm

If Jeff or anyone has any ideas one what to try let me know plz
My only thought was using arrays but I'm not familiar with them.

Thanks,
JD

Jeff Boyce said:
It sounds like you are saying you'd like to have multiple rows in your
[Schedule] table for a given [TechID], for a given [Location] (?why not a
[LocationID]), for multiple dates (your date range).

By the way, MS Access treats the word "Date" as a reserved word. What
YOU
mean by that and what Access means by that may not always be the same.
If
you don't want to risk a misunderstanding, consider changing the name of
that field to something more meaningful (and less "reserved") ...
?ScheduledDate?

In Access, it all starts with the data. Forms are convenient ways to
add/edit data, but tables store it.

Since you appear to already have a one-to-many relationship between
[TechID]
and [Schedule], you could use a standard Access approach. Create a main
form that displays "Tech" information. Create another form that displays
rows from the [Schedule] table. Rather than using a continuous form, try
"Single Form", but make it tall enough to show many rows. Embed that
second
form as a subform within your main form, and remind Access that [TechID]
is
the field they share in common.

Now, when you want to show a Tech scheduled for multiple days, add
multiple
rows. This approach also gives you the flexibility of "scheduling" a
Tech
for Monday - Wednesday - Friday, or ...

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP


I am having problems trying to store multiple date entries for a
schedule
database.
So far I have a form that a user can select a technician and date and
type
in what they are to do for that day. Problem is, often these techs
will
be
on the same job for 2 weeks or even a month. As the form is now, you
can
schedule one or more techs for one day at once, but you can't schedule
one
or
more for mult days all at once.

Is it possible to declare a date range and schedule given tech for that
range?
The table that the form makes records in looks like this.

ScheduleID : TechID : Date : Location
: Comments

([Tech ID] references a Tech Table)

Thanks,
JD
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top