我正在尝试编写一个脚本,根据另一个表中的数据将记录加载到表中。 步骤如下:
这是在SQL中,我是编程新手。任何有关代码的帮助都将非常感激。
Table1 - Source table and has 3 columns
Material Num Mfg Date Sold Date
1 1/1/2013 1/15/2013
2 2/1/2013 null
3 3/1/2013 null
4 4/1/2013 4/15/2013
5 5/1/2013 5/15/2013
Table2 Target table
Month/ Yr Count
Jan-13 0
Feb-13 0
Mar-13 1
Apr-13 2
May-13 2