update vers 550 x nuova procedura (TSQL) x creazione odette
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Generated
+147
-71
@@ -7174,112 +7174,124 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
private void InitCommandCollection() {
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[10];
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[11];
|
||||
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = "SELECT * FROM dbo.Odette";
|
||||
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
||||
this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[1].Connection = this.Connection;
|
||||
this._commandCollection[1].CommandText = "dbo.stp_ODETTE_deleteByLDP";
|
||||
this._commandCollection[1].CommandText = "dbo.stp_ODETTE_caricaDatiBollaEtichettaOdette";
|
||||
this._commandCollection[1].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numBolla", global::System.Data.SqlDbType.NVarChar, 6, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@dataBolla", global::System.Data.SqlDbType.NVarChar, 8, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@GrpBolla", global::System.Data.SqlDbType.NVarChar, 1, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Particolare", global::System.Data.SqlDbType.NVarChar, 15, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[2] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[2].Connection = this.Connection;
|
||||
this._commandCollection[2].CommandText = "dbo.stp_ODETTE_delete";
|
||||
this._commandCollection[2].CommandText = "dbo.stp_ODETTE_deleteByLDP";
|
||||
this._commandCollection[2].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CampoUDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[3].Connection = this.Connection;
|
||||
this._commandCollection[3].CommandText = "dbo.stp_ODETTE_getByBolla";
|
||||
this._commandCollection[3].CommandText = "dbo.stp_ODETTE_delete";
|
||||
this._commandCollection[3].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@GrpBolla", global::System.Data.SqlDbType.NVarChar, 1, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@NumBolla", global::System.Data.SqlDbType.Decimal, 5, global::System.Data.ParameterDirection.Input, 6, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@DataBolla", global::System.Data.SqlDbType.Decimal, 5, global::System.Data.ParameterDirection.Input, 8, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Particolare", global::System.Data.SqlDbType.NVarChar, 15, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CampoUDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[4].Connection = this.Connection;
|
||||
this._commandCollection[4].CommandText = "dbo.stp_ODETTE_getByListaPrelievo";
|
||||
this._commandCollection[4].CommandText = "dbo.stp_ODETTE_getByBolla";
|
||||
this._commandCollection[4].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@GrpBolla", global::System.Data.SqlDbType.NVarChar, 1, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@NumBolla", global::System.Data.SqlDbType.Decimal, 5, global::System.Data.ParameterDirection.Input, 6, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@DataBolla", global::System.Data.SqlDbType.Decimal, 5, global::System.Data.ParameterDirection.Input, 8, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Particolare", global::System.Data.SqlDbType.NVarChar, 15, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[5] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[5].Connection = this.Connection;
|
||||
this._commandCollection[5].CommandText = "dbo.stp_ODETTE_getByUDC";
|
||||
this._commandCollection[5].CommandText = "dbo.stp_ODETTE_getByListaPrelievo";
|
||||
this._commandCollection[5].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[5].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[5].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[5].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[6] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[6].Connection = this.Connection;
|
||||
this._commandCollection[6].CommandText = "dbo.stp_ODETTE_setStato";
|
||||
this._commandCollection[6].CommandText = "dbo.stp_ODETTE_getByUDC";
|
||||
this._commandCollection[6].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@StatoOk", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[7].Connection = this.Connection;
|
||||
this._commandCollection[7].CommandText = "dbo.stp_ODETTE_updateLingua";
|
||||
this._commandCollection[7].CommandText = "dbo.stp_ODETTE_setStato";
|
||||
this._commandCollection[7].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo1_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo2_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo3_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo4_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo5_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo6_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo7_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo8_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo9_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo10_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo11_1_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo11_2_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo12_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo13_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo14_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo15_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo16_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[7].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@StatoOk", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[8].Connection = this.Connection;
|
||||
this._commandCollection[8].CommandText = "dbo.stp_ODETTE_updateVal";
|
||||
this._commandCollection[8].CommandText = "dbo.stp_ODETTE_updateLingua";
|
||||
this._commandCollection[8].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ragSocCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@indirCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@capCittCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ragSocDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@indirDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@capCittDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pesoNetto", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pesoLordo", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numColli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@disPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codImb", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codMaz", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codNael", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codAQP", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo1_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo2_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo3_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo4_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo5_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo6_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo7_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo8_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo9_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo10_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo11_1_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo11_2_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo12_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo13_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo14_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo15_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Campo16_1", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[9].Connection = this.Connection;
|
||||
this._commandCollection[9].CommandText = "dbo.stp_ODETTE_upsertUdc";
|
||||
this._commandCollection[9].CommandText = "dbo.stp_ODETTE_updateVal";
|
||||
this._commandCollection[9].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.VarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numBolla", global::System.Data.SqlDbType.NVarChar, 6, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@dataBolla", global::System.Data.SqlDbType.NVarChar, 8, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@GrpBolla", global::System.Data.SqlDbType.NVarChar, 1, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Particolare", global::System.Data.SqlDbType.NVarChar, 15, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IndStabFrom", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@qtaCont", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ragSocCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@indirCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@capCittCli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ragSocDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@indirDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@capCittDest", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pesoNetto", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pesoLordo", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numColli", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@disPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codPart", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codImb", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codMaz", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codNael", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@codAQP", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[10].Connection = this.Connection;
|
||||
this._commandCollection[10].CommandText = "dbo.stp_ODETTE_upsertUdc";
|
||||
this._commandCollection[10].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@UDC", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.VarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numBolla", global::System.Data.SqlDbType.NVarChar, 6, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@dataBolla", global::System.Data.SqlDbType.NVarChar, 8, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@GrpBolla", global::System.Data.SqlDbType.NVarChar, 1, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Particolare", global::System.Data.SqlDbType.NVarChar, 15, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLista", global::System.Data.SqlDbType.NVarChar, 12, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IndStabFrom", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[10].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@qtaCont", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
}
|
||||
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
@@ -7311,7 +7323,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
|
||||
public virtual DS_Odette.OdetteDataTable getByBolla(string CodMag, string GrpBolla, global::System.Nullable<decimal> NumBolla, global::System.Nullable<decimal> DataBolla, string Particolare) {
|
||||
this.Adapter.SelectCommand = this.CommandCollection[3];
|
||||
this.Adapter.SelectCommand = this.CommandCollection[4];
|
||||
if ((CodMag == null)) {
|
||||
this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -7352,7 +7364,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
|
||||
public virtual DS_Odette.OdetteDataTable getByCodLista(string CodLista) {
|
||||
this.Adapter.SelectCommand = this.CommandCollection[4];
|
||||
this.Adapter.SelectCommand = this.CommandCollection[5];
|
||||
if ((CodLista == null)) {
|
||||
this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -7369,7 +7381,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
|
||||
public virtual DS_Odette.OdetteDataTable getByUdc(string UDC) {
|
||||
this.Adapter.SelectCommand = this.CommandCollection[5];
|
||||
this.Adapter.SelectCommand = this.CommandCollection[6];
|
||||
if ((UDC == null)) {
|
||||
this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10103,8 +10115,72 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
public virtual int deleteByLDP(string CodLista) {
|
||||
public virtual int caricaDatiBollaEtichettaOdette(string CodCS, string UDC, string numBolla, string dataBolla, string CodMag, string GrpBolla, string Particolare) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[1];
|
||||
if ((CodCS == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[1].Value = ((string)(CodCS));
|
||||
}
|
||||
if ((UDC == null)) {
|
||||
command.Parameters[2].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[2].Value = ((string)(UDC));
|
||||
}
|
||||
if ((numBolla == null)) {
|
||||
command.Parameters[3].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[3].Value = ((string)(numBolla));
|
||||
}
|
||||
if ((dataBolla == null)) {
|
||||
command.Parameters[4].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[4].Value = ((string)(dataBolla));
|
||||
}
|
||||
if ((CodMag == null)) {
|
||||
command.Parameters[5].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[5].Value = ((string)(CodMag));
|
||||
}
|
||||
if ((GrpBolla == null)) {
|
||||
command.Parameters[6].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[6].Value = ((string)(GrpBolla));
|
||||
}
|
||||
if ((Particolare == null)) {
|
||||
command.Parameters[7].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[7].Value = ((string)(Particolare));
|
||||
}
|
||||
global::System.Data.ConnectionState previousConnectionState = command.Connection.State;
|
||||
if (((command.Connection.State & global::System.Data.ConnectionState.Open)
|
||||
!= global::System.Data.ConnectionState.Open)) {
|
||||
command.Connection.Open();
|
||||
}
|
||||
int returnValue;
|
||||
try {
|
||||
returnValue = command.ExecuteNonQuery();
|
||||
}
|
||||
finally {
|
||||
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
||||
command.Connection.Close();
|
||||
}
|
||||
}
|
||||
return returnValue;
|
||||
}
|
||||
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
public virtual int deleteByLDP(string CodLista) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[2];
|
||||
if ((CodLista == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10132,7 +10208,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
public virtual int deleteQuery(string Original_CampoUDC) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[2];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[3];
|
||||
if ((Original_CampoUDC == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10160,7 +10236,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
public virtual int setStato(string UDC, global::System.Nullable<bool> StatoOk) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[6];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[7];
|
||||
if ((UDC == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10212,7 +10288,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
string Campo14_1,
|
||||
string Campo15_1,
|
||||
string Campo16_1) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[7];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[8];
|
||||
if ((UDC == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10359,7 +10435,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
string codMaz,
|
||||
string codNael,
|
||||
string codAQP) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[8];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[9];
|
||||
if ((UDC == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -10483,7 +10559,7 @@ SELECT CDMFS, GRBOS, DTBOS, NRBOS, CDARS, NRRGS, CDINB, RA1ND, RA2ND, CAPND, CIT
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
public virtual int upsertUdc(string UDC, string CodCS, string numBolla, string dataBolla, string CodMag, string GrpBolla, string Particolare, string CodLista, string IndStabFrom, string qtaCont) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[9];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[10];
|
||||
if ((UDC == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
|
||||
@@ -765,6 +765,23 @@ SELECT CampoUDC, Campo1_1, Campo1_2, Campo1_3, Campo1_4, Campo1_5, Campo2_1, Cam
|
||||
<Mapping SourceColumn="CodCS" DataSetColumn="CodCS" />
|
||||
</Mappings>
|
||||
<Sources>
|
||||
<DbSource ConnectionRef="GMWConnectionString (Settings)" DbObjectName="TK_GMWTest.dbo.stp_ODETTE_caricaDatiBollaEtichettaOdette" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="caricaDatiBollaEtichettaOdette" Modifier="Public" Name="caricaDatiBollaEtichettaOdette" QueryType="NoData" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy6" UserSourceName="caricaDatiBollaEtichettaOdette">
|
||||
<SelectCommand>
|
||||
<DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
|
||||
<CommandText>dbo.stp_ODETTE_caricaDatiBollaEtichettaOdette</CommandText>
|
||||
<Parameters>
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="int" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@CodCS" Precision="0" ProviderType="NVarChar" Scale="0" Size="2" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@UDC" Precision="0" ProviderType="NVarChar" Scale="0" Size="50" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@numBolla" Precision="0" ProviderType="NVarChar" Scale="0" Size="6" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@dataBolla" Precision="0" ProviderType="NVarChar" Scale="0" Size="8" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@CodMag" Precision="0" ProviderType="NVarChar" Scale="0" Size="2" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@GrpBolla" Precision="0" ProviderType="NVarChar" Scale="0" Size="1" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@Particolare" Precision="0" ProviderType="NVarChar" Scale="0" Size="15" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
</Parameters>
|
||||
</DbCommand>
|
||||
</SelectCommand>
|
||||
</DbSource>
|
||||
<DbSource ConnectionRef="GMWConnectionString (Settings)" DbObjectName="SP_GMW.dbo.stp_ODETTE_deleteByLDP" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="deleteByLDP" Modifier="Public" Name="deleteByLDP" QueryType="NoData" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy" UserSourceName="deleteByLDP">
|
||||
<SelectCommand>
|
||||
<DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
|
||||
|
||||
@@ -6,10 +6,9 @@
|
||||
</autogenerated>-->
|
||||
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="0" ViewPortY="0" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
|
||||
<Shapes>
|
||||
<Shape ID="DesignTable:BORI202J" ZOrder="3" X="848" Y="147" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
|
||||
<Shape ID="DesignTable:BORI202J" ZOrder="2" X="848" Y="147" Height="381" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
|
||||
<Shape ID="DesignTable:Odette" ZOrder="1" X="237" Y="227" Height="476" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="254" />
|
||||
<Shape ID="DesignTable:stp_OdetteStatoCreate" ZOrder="4" X="734" Y="647" Height="115" Width="276" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
|
||||
<Shape ID="DesignTable:ANODM00F" ZOrder="2" X="289" Y="763" Height="172" Width="291" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="102" />
|
||||
<Shape ID="DesignTable:stp_OdetteStatoCreate" ZOrder="3" X="734" Y="647" Height="115" Width="276" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="64" />
|
||||
</Shapes>
|
||||
<Connectors />
|
||||
</DiagramLayout>
|
||||
@@ -423,6 +423,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="SqlScripts\V1.2\GMW_410_TEKAL\Sincroniz da TK_GMWTest a TK_GMW NON USARE.txt" />
|
||||
<None Include="SqlScripts\V2.2_TK\GMW_00550.sql" />
|
||||
<Content Include="SqlScripts\V2.2_TK\GMW_00540_pre_Install.sql" />
|
||||
<None Include="SqlScripts\V2.2_TK\GMW_00540.sql" />
|
||||
<None Include="SqlScripts\V2.2_TK\GMW_00533.sql" />
|
||||
|
||||
+14
-6
@@ -118,11 +118,8 @@ namespace GMW_data
|
||||
/// <returns></returns>
|
||||
protected bool caricaDatiBollaEtichettaOdette(string UDC, string RaggMag, string GrpBolla, decimal numBolla, decimal dataBolla, string particolare)
|
||||
{
|
||||
// !!!FARE!!! modifica: controllo solo se ha trovato dati in BORIJ poi chiamo stored!
|
||||
|
||||
//stp_ODETTE_caricaDatiBollaEtichettaOdette
|
||||
|
||||
|
||||
// versione vecchia: ora faccio tutto con stored!
|
||||
#if false
|
||||
bool answ = false;
|
||||
string ragSocCli = "";
|
||||
string indirCli = "";
|
||||
@@ -363,7 +360,7 @@ namespace GMW_data
|
||||
{
|
||||
logger.lg.scriviLog("Errore campo16 (016)", tipoLog.ERROR);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (trovati >= 1)
|
||||
{
|
||||
try
|
||||
@@ -376,6 +373,17 @@ namespace GMW_data
|
||||
answ = false;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
bool answ = false;
|
||||
try
|
||||
{
|
||||
taOdette.caricaDatiBollaEtichettaOdette(memLayer.ML.confReadString("CodCS"), UDC, numBolla.ToString(), dataBolla.ToString(), RaggMag, GrpBolla, particolare);
|
||||
answ = true;
|
||||
}
|
||||
catch
|
||||
{
|
||||
answ = false;
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,329 @@
|
||||
set ANSI_NULLS on;
|
||||
go
|
||||
|
||||
/***************************************
|
||||
* FUNCTION f_calcDestOdette
|
||||
*
|
||||
* Compongo il primo campo delle odette ( campo_2 ) x il destinatario/molo
|
||||
*
|
||||
* Steamware, S.E.L.
|
||||
* mod: 14/05/2013
|
||||
*
|
||||
****************************************/
|
||||
create FUNCTION f_odetteCalcDest (@INEND VARCHAR(50) , @CCDMOL VARCHAR(50), @CCDPTR VARCHAR(50), @CDINB VARCHAR(50),
|
||||
@CRAGCL VARCHAR(50) , @TELND VARCHAR(50)
|
||||
)
|
||||
RETURNS NVARCHAR(50) AS
|
||||
BEGIN
|
||||
|
||||
DECLARE @answ NVARCHAR(50) = ''
|
||||
DECLARE @destP1A NVARCHAR(50) = ''
|
||||
DECLARE @destP2A NVARCHAR(50) = ''
|
||||
DECLARE @destP1 NVARCHAR(50) = ''
|
||||
DECLARE @destP2 NVARCHAR(50) = ''
|
||||
DECLARE @destP3 NVARCHAR(50) = ''
|
||||
|
||||
-- Se il campo INEND è vuoto devo prendere sempre gli altri campi CCDMOL e CCDPTR
|
||||
SET @destP1A = CASE WHEN (SUBSTRING(@INEND,1,30)) = '' THEN (@CCDMOL) ELSE dbo.f_trim(SUBSTRING(@INEND,16,15)) END
|
||||
SET @destP2A = CASE WHEN (SUBSTRING(@INEND,1,30)) = '' THEN (@CCDPTR) ELSE dbo.f_trim(SUBSTRING(@INEND,1,15)) END
|
||||
|
||||
SET @destP1 = CASE WHEN (@CDINB) <> '' THEN @destP1A ELSE (@CCDMOL) END
|
||||
SET @destP2 = CASE WHEN (@CDINB) <> '' THEN @destP2A ELSE (@CCDPTR) END
|
||||
|
||||
-- solo se BMW metto /S
|
||||
SET @destP3 = CASE WHEN @CRAGCL = '13' OR ( @CDINB <> '' AND SUBSTRING(@TELND,19,2) = '13') THEN '/S' ELSE '' END
|
||||
|
||||
IF @destP1 + @destP2 <> ''
|
||||
SET @answ = @destP1 + '/' + @destP2 + @destP3
|
||||
ELSE
|
||||
SET @answ = ''
|
||||
|
||||
RETURN @answ
|
||||
|
||||
END
|
||||
go
|
||||
|
||||
/***************************************
|
||||
* FUNCTION f_odetteCalcNAEL
|
||||
*
|
||||
* Compongo il primo campo delle odette campo 14 ( Change Index ) o codice NAEL + esponente di modifica particolare )
|
||||
*
|
||||
* Steamware, S.E.L.
|
||||
* mod: 14/05/2013
|
||||
*
|
||||
****************************************/
|
||||
create FUNCTION f_odetteCalcNAEL (@CRAGCL VARCHAR(50) , @TELND VARCHAR(50), @ECDNAE VARCHAR(50),@ECDNA1 VARCHAR(50)
|
||||
,@EESPMD VARCHAR(50), @OCDODM VARCHAR(50)
|
||||
)
|
||||
RETURNS NVARCHAR(50) AS
|
||||
BEGIN
|
||||
|
||||
DECLARE @answ NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP1 NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP2 NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP3 NVARCHAR(50) = ''
|
||||
|
||||
-- Se il cliente è BMW calcolo campi x NAEL
|
||||
SET @codNaelP1 = CASE WHEN dbo.f_trim(@CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(@TELND,19,2)) = '13' THEN dbo.f_trim(@ECDNAE) ELSE '' END
|
||||
SET @codNaelP2 = CASE WHEN dbo.f_trim(@CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(@TELND,19,2)) = '13' THEN dbo.f_trim(@ECDNA1) ELSE '' END
|
||||
SET @codNaelP3 = CASE WHEN dbo.f_trim(@CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(@TELND,19,2)) = '13' THEN dbo.f_trim(@EESPMD) ELSE '' END
|
||||
|
||||
|
||||
SET @answ = CASE WHEN dbo.f_trim(@CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(@TELND,19,2)) = '13'
|
||||
THEN 'ZI:'+ @codNaelP1 + ' ' + @codNaelP2 + ' AI:'+ @codNaelP3
|
||||
ELSE @OCDODM -- se non BMW
|
||||
END
|
||||
|
||||
RETURN @answ
|
||||
|
||||
END
|
||||
go
|
||||
|
||||
|
||||
set xact_abort on;
|
||||
go
|
||||
|
||||
begin transaction;
|
||||
go
|
||||
|
||||
set ANSI_NULLS on;
|
||||
go
|
||||
|
||||
/*****************************************
|
||||
* STORED stp_ODETTE_updateVal
|
||||
*
|
||||
* effettua aggiornamento valori etichetta Odette
|
||||
*
|
||||
* Steamware, S.E.L.
|
||||
* mod: 2011.04.28
|
||||
*
|
||||
****************************************/
|
||||
alter PROCEDURE stp_ODETTE_updateVal
|
||||
(
|
||||
@UDC NVARCHAR(50),
|
||||
@ragSocCli NVARCHAR(50),
|
||||
@indirCli NVARCHAR(50),
|
||||
@capCittCli NVARCHAR(50),
|
||||
@ragSocDest NVARCHAR(50),
|
||||
@indirDest NVARCHAR(50),
|
||||
@capCittDest NVARCHAR(50),
|
||||
@pesoNetto NVARCHAR(50),
|
||||
@pesoLordo NVARCHAR(50),
|
||||
@numColli NVARCHAR(50),
|
||||
@disPart NVARCHAR(50),
|
||||
@descPart NVARCHAR(50),
|
||||
@codPart NVARCHAR(50),
|
||||
@codImb NVARCHAR(50),
|
||||
@codMaz NVARCHAR(50),
|
||||
@codNael NVARCHAR(50),
|
||||
@codAQP NVARCHAR(50)
|
||||
)
|
||||
AS
|
||||
|
||||
-- COMMIT TRAN
|
||||
|
||||
|
||||
-- update valori (sovrascrivo...)
|
||||
UPDATE Odette
|
||||
SET Campo1_2 = @ragSocCli,
|
||||
Campo1_3 = @indirCli,
|
||||
Campo1_4 = @capCittCli,
|
||||
Campo2_2 = @ragSocDest,
|
||||
Campo2_3 = @indirDest,
|
||||
Campo2_4 = @capCittDest,
|
||||
Campo5_2 = @pesoNetto,
|
||||
Campo6_2 = @pesoLordo,
|
||||
Campo7_2 = @numColli,
|
||||
Campo8_2 = @disPart,
|
||||
Campo8_3 = @disPart,
|
||||
Campo10_2 = @descPart,
|
||||
Campo11_1_2 = @codPart,
|
||||
Campo11_1_3 = @codPart,
|
||||
Campo11_2_2 = @codImb,
|
||||
Campo11_2_3 = @codImb,
|
||||
Campo12_2 = @codMaz,
|
||||
Campo12_3 = @codMaz,
|
||||
Campo14_2 = @codNael,
|
||||
Campo16_5 = ISNULL(@codAQP,'')
|
||||
|
||||
WHERE CampoUDC = @UDC
|
||||
|
||||
RETURN
|
||||
go
|
||||
|
||||
commit;
|
||||
go
|
||||
|
||||
|
||||
set xact_abort on;
|
||||
go
|
||||
|
||||
begin transaction;
|
||||
go
|
||||
|
||||
set ANSI_NULLS on;
|
||||
go
|
||||
|
||||
/*****************************************
|
||||
* STORED stp_ODETTE_caricaDatiBollaEtichettaOdette
|
||||
*
|
||||
* carica i dati x odette dai valori delel tab lette da as400 (rimpiazza procedura c#)
|
||||
*
|
||||
* Steamware, S.E.L.
|
||||
* mod: 2011.04.28
|
||||
*
|
||||
****************************************/
|
||||
alter PROCEDURE stp_ODETTE_caricaDatiBollaEtichettaOdette
|
||||
(
|
||||
@CodCS NVARCHAR(2),
|
||||
@UDC NVARCHAR(50),
|
||||
@numBolla NVARCHAR(6),
|
||||
@dataBolla NVARCHAR(8),
|
||||
@CodMag NVARCHAR(2),
|
||||
@GrpBolla NVARCHAR(1),
|
||||
@Particolare NVARCHAR(15)
|
||||
)
|
||||
|
||||
AS
|
||||
|
||||
SET NOCOUNT ON
|
||||
/* Dichiarazione variabili iniziale */
|
||||
|
||||
DECLARE @ragSocCli NVARCHAR(50) = ''
|
||||
DECLARE @indirCli NVARCHAR(50) = ''
|
||||
DECLARE @capCittCli NVARCHAR(50) = ''
|
||||
DECLARE @destinatario NVARCHAR(50) = ''
|
||||
DECLARE @ragSocDest NVARCHAR(50) = ''
|
||||
DECLARE @indirDest NVARCHAR(50) = ''
|
||||
DECLARE @capCittDest NVARCHAR(50) = ''
|
||||
DECLARE @peso NUMERIC(7,3) = 0
|
||||
DECLARE @pesoNetto NVARCHAR(50) = ''
|
||||
DECLARE @pesoLordo NVARCHAR(50) = ''
|
||||
DECLARE @numColli NVARCHAR(50) = ''
|
||||
DECLARE @disPart NVARCHAR(50) = ''
|
||||
DECLARE @descPart NVARCHAR(50) = ''
|
||||
DECLARE @codPart NVARCHAR(50) = ''
|
||||
DECLARE @codImb NVARCHAR(50) = ''
|
||||
DECLARE @codMaz NVARCHAR(50) = ''
|
||||
DECLARE @codNael NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP1 NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP2 NVARCHAR(50) = ''
|
||||
DECLARE @codNaelP3 NVARCHAR(50) = ''
|
||||
DECLARE @codAQP NVARCHAR(50) = ''
|
||||
|
||||
-- altre variabili accessorie
|
||||
DECLARE @trovati INT = 0
|
||||
DECLARE @qtaUdc INT = 1
|
||||
|
||||
-- in primis recupero la riga di dati da AS400...
|
||||
SELECT @trovati = COUNT(*)
|
||||
FROM RawData.BORI202J
|
||||
WHERE CDMFS = @CodMag
|
||||
AND GRBOS = @GrpBolla
|
||||
AND NRBOS = @numBolla
|
||||
AND DTBOS = @DataBolla
|
||||
AND CDARS = @Particolare
|
||||
|
||||
-- carico i dati dell'UDC
|
||||
SELECT @qtaUdc = Qta
|
||||
FROM ElencoCartellini
|
||||
WHERE UDC = @UDC
|
||||
|
||||
-- proseguo solo se ho trovato la bolla!
|
||||
IF(@trovati > 0)
|
||||
BEGIN
|
||||
|
||||
SELECT TOP 1
|
||||
-- campo 1 indirizzo destinazione cliente ( Receiver )
|
||||
@ragSocCli = CASE WHEN dbo.f_trim(CDINB) <> '' AND @CodCS <> 'TK' THEN dbo.f_trim(RA1ND) ELSE dbo.f_trim(RASCL) END
|
||||
,@indirCli = CASE WHEN dbo.f_trim(CDINB) <> '' AND @CodCS <> 'TK' THEN dbo.f_trim(RA2ND) ELSE dbo.f_trim(INDCL) END
|
||||
,@capCittCli = CASE WHEN dbo.f_trim(CDINB) <> '' AND @CodCS <> 'TK' THEN dbo.f_trim(CAPND) + ' ' + dbo.f_trim(CITND)
|
||||
ELSE dbo.f_trim(CAPCL) + ' ' + dbo.f_trim(LOCCL) + ' ' +dbo.f_trim(PROCL) END
|
||||
|
||||
-- campo 2 punto di rifornimento / molo / uso ( Destination )
|
||||
-- ATTENZIONE NON POSSO TESTARE QUI LE VARIABILI MA SOLO ASSEGNARLE!!! NEL CASE LE VALUTA SEMPRE VUOTE
|
||||
,@destinatario = dbo.f_odetteCalcDest( dbo.f_trim(INEND), dbo.f_trim(CCDMOL), dbo.f_trim(CCDPTR), dbo.f_trim(CDINB),
|
||||
dbo.f_trim(CRAGCL), dbo.f_trim(TELND) )
|
||||
|
||||
-- Leggo i dati che mi servono dopo nel caso il destinatario sia vuoto ( VEDI DOPO SELECT )
|
||||
,@ragSocDest = dbo.f_trim(RA1ND)
|
||||
,@indirDest = dbo.f_trim(RA2ND)
|
||||
,@capCittDest = dbo.f_trim(CAPND) + ' ' + dbo.f_trim(CITND)
|
||||
|
||||
-- campo 5_2 peso netto ( Net Weight )
|
||||
,@peso = CASE WHEN ISNULL(EPLAVO,0) <= 0 THEN EPNETT ELSE EPLAVO END
|
||||
,@pesoNetto = CONVERT(NVARCHAR(50), CONVERT(INT , FLOOR( @peso * @qtaUdc ) ) )
|
||||
|
||||
-- campo 6_2 peso lordo (Gross Weight)
|
||||
,@pesoLordo = CONVERT(NVARCHAR(50), CONVERT(INT, FLOOR( PELDB / NRC1B ) ) )
|
||||
|
||||
-- campo 7 numero colli (Nr. Boxes)
|
||||
,@numColli = CONVERT(NVARCHAR(50), 1) -- imposto n. colli del cartellino odette fisso = 1
|
||||
-- ,@numColli = CONVERT(NVARCHAR(50), NRC1B)
|
||||
|
||||
-- campo 8 disegno particolare ( Part Number )
|
||||
,@disPart = dbo.f_trim(ECMM01)
|
||||
|
||||
-- campo 10 Descrizione particolare ( Description )
|
||||
,@descPart = dbo.f_trim(DEPAR)
|
||||
|
||||
-- campo 11_1 Codice particolare (non stampato)
|
||||
,@codPart = dbo.f_trim(CDARS)
|
||||
-- campo 11_2 Codice imballo per il cliente ( Logistics Reference )
|
||||
,@codImb = dbo.f_trim(FCDI01)
|
||||
|
||||
-- campo 12 Codice Mazzucconi/Tekal/Possidonio per il cliente ( Supplier )
|
||||
,@codMaz = CASE WHEN dbo.f_trim(CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(TELND,19,2)) = '13' THEN
|
||||
CASE WHEN dbo.f_trim(CDINB) <> '' AND dbo.f_trim(PERND) <> '' THEN dbo.f_trim(PERND)
|
||||
WHEN dbo.f_trim(CDINB) = '' AND dbo.f_trim(CCDET1) <> '' THEN dbo.f_trim(CCDET1)
|
||||
ELSE dbo.f_trim(CCFOE1) END
|
||||
ELSE dbo.f_trim(CCFOE1) END
|
||||
|
||||
-- campo 14 codice NAEL + esponente di modifica particolare ( Change Index )
|
||||
,@codNael = dbo.f_odetteCalcNAEL ( dbo.f_trim(CRAGCL),dbo.f_trim(TELND),dbo.f_trim(ECDNAE),dbo.f_trim(ECDNA1),
|
||||
dbo.f_trim(EESPMD),dbo.f_trim(OCDODM) )
|
||||
|
||||
--,@codNaelP1 = CASE WHEN dbo.f_trim(CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(TELND,19,2)) = '13' THEN dbo.f_trim(ECDNAE) ELSE '' END
|
||||
--,@codNaelP2 = CASE WHEN dbo.f_trim(CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(TELND,19,2)) = '13' THEN dbo.f_trim(ECDNA1) ELSE '' END
|
||||
--,@codNaelP3 = CASE WHEN dbo.f_trim(CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(TELND,19,2)) = '13' THEN dbo.f_trim(EESPMD) ELSE '' END
|
||||
--,@codNael = CASE WHEN dbo.f_trim(CRAGCL) = '13' OR dbo.f_trim(SUBSTRING(TELND,19,2)) = '13' THEN 'ZI:'+ @codNaelP1 + ' ' + @codNaelP2 + ' AI:'+ @codNaelP3 ELSE OCDODM END
|
||||
|
||||
-- campo 16_5 AQP ( controllo qualità )
|
||||
,@codAQP = dbo.f_trim(ECLAQP)
|
||||
|
||||
FROM RawData.BORI202J
|
||||
WHERE CDMFS = @CodMag
|
||||
AND GRBOS = @GrpBolla
|
||||
AND NRBOS = @numBolla
|
||||
AND DTBOS = @DataBolla
|
||||
AND CDARS = @Particolare
|
||||
|
||||
-- Se nella destinazione non trovo nulla utilizzo i dati in RA1ND RA2ND CAPND CITND ( simile indirizzo cliente )
|
||||
IF @destinatario = ''
|
||||
SET @destinatario = @ragSocDest
|
||||
ELSE
|
||||
BEGIN -- vuoto i campi necessari solo se destinatario NON è vuoto ( in questo caso compilo solo prima riga )
|
||||
SET @indirDest = ''
|
||||
SET @capCittDest = ''
|
||||
END
|
||||
|
||||
-- SELECT @UDC, @ragSocCli, @indirCli, @capCittCli, @destinatario, @indirDest, @capCittDest, @pesoNetto, @pesoLordo, @numColli, @disPart, @descPart, @codPart, @codImb, @codMaz, @codNael, @codAQP
|
||||
EXEC stp_ODETTE_updateVal @UDC, @ragSocCli, @indirCli, @capCittCli, @destinatario, @indirDest, @capCittDest, @pesoNetto, @pesoLordo, @numColli, @disPart, @descPart, @codPart, @codImb, @codMaz, @codNael, @codAQP
|
||||
|
||||
END
|
||||
|
||||
RETURN
|
||||
go
|
||||
|
||||
commit;
|
||||
go
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
-- registro versione...
|
||||
INSERT INTO [dbo].[LogUpdateDb] ([Versione],[Data]) VALUES(550, GETDATE())
|
||||
GO
|
||||
SELECT TOP 5 * FROM LogUpdateDb ORDER BY Versione DESC
|
||||
GO
|
||||
Reference in New Issue
Block a user