Dear all,
1. Assume TableA stores the holiday dates (exclude Saturday and Sunday) of a year,
HDays Year
----- -----
01-01-2009 2009
10-04-2009 2009
13-04-2009 2009
...etc
2.) Right now, I have to insert record to TableB so that it will contains the working dates of 2009. The holiday dates can be found from TableA and these dates should be excluded in TableB. Besides, TableB should exclude the dates of Saturday and Sunday.
How to write a query for that case? (similar to that
insert into tableb(workdate, year)
select .... from TableA...
Many thanks
1. Assume TableA stores the holiday dates (exclude Saturday and Sunday) of a year,
HDays Year
----- -----
01-01-2009 2009
10-04-2009 2009
13-04-2009 2009
...etc
2.) Right now, I have to insert record to TableB so that it will contains the working dates of 2009. The holiday dates can be found from TableA and these dates should be excluded in TableB. Besides, TableB should exclude the dates of Saturday and Sunday.
How to write a query for that case? (similar to that

insert into tableb(workdate, year)
select .... from TableA...
Many thanks