diff --git a/Data/Migrations/Migration_12_Alter_Kit_Table_With_Type.asp b/Data/Migrations/Migration_12_Alter_Kit_Table_With_Type.asp new file mode 100644 index 0000000..c1f2c59 --- /dev/null +++ b/Data/Migrations/Migration_12_Alter_Kit_Table_With_Type.asp @@ -0,0 +1,16 @@ +<% +Class Migration_12_Alter_Kit_Table_With_Type + Public Migration + + Public Sub Up + Migration.Do "ALTER TABLE [Kit] " &_ + "ADD [JobType] VARCHAR(50);" +End Sub + + Public Sub Down + Migration.Do "ALTER TABLE [Kit] " &_ + "DROP COLUMN [JobType];" + End Sub +End Class + Migrations.Add "Migration_12_Alter_Kit_Table_With_Type" + %> \ No newline at end of file diff --git a/Data/Migrations/migrate.asp b/Data/Migrations/migrate.asp index eed956c..7c37604 100644 --- a/Data/Migrations/migrate.asp +++ b/Data/Migrations/migrate.asp @@ -40,6 +40,7 @@ Migrations.Tracing = false + <% Sub HandleMigration putl "Starting Version: " & Migrations.Version & "" diff --git a/ImportService/TrackingDataImport.vbs b/ImportService/TrackingDataImport.vbs index b5f601d..583422e 100644 --- a/ImportService/TrackingDataImport.vbs +++ b/ImportService/TrackingDataImport.vbs @@ -73,7 +73,7 @@ Dim JCode:JCode = Left(Filename,5) Dim oConn:Set oConn = WScript.CreateObject("ADODB.Connection") oConn.ConnectionString = ConnectionString oConn.Open - oConn.Execute("Insert Into Kit ([JobNumber], [Jcode], [CreatedOn]) VALUES ('" & JobNumber & "','" & JCode & "',#" & Now() & "#);") + oConn.Execute("Insert Into Kit ([JobNumber], [Jcode], [CreatedOn], [JobType]) VALUES ('" & JobNumber & "','" & JCode & "',#" & Now() & "#,'Purple Envelopes');") Dim rs : set rs = oConn.Execute("Select TOP 1 ID from Kit ORDER BY ID DESC") Dim kitId : kitId = rs("ID").value rs.close