That didn't work, trying with TableAdapter.FillSchema(DataSet, SchemaType.Source)
parent
462fc84eb2
commit
056b2940b4
|
@ -108,11 +108,13 @@ namespace OpenSim.Framework.Data.MySQL
|
||||||
m_primTable = createPrimTable();
|
m_primTable = createPrimTable();
|
||||||
m_dataSet.Tables.Add(m_primTable);
|
m_dataSet.Tables.Add(m_primTable);
|
||||||
SetupPrimCommands(m_primDataAdapter, m_connection);
|
SetupPrimCommands(m_primDataAdapter, m_connection);
|
||||||
|
m_primDataAdapter.FillSchema(m_primTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_primDataAdapter.Fill(m_primTable);
|
m_primDataAdapter.Fill(m_primTable);
|
||||||
|
|
||||||
m_shapeTable = createShapeTable();
|
m_shapeTable = createShapeTable();
|
||||||
m_dataSet.Tables.Add(m_shapeTable);
|
m_dataSet.Tables.Add(m_shapeTable);
|
||||||
SetupShapeCommands(m_shapeDataAdapter, m_connection);
|
SetupShapeCommands(m_shapeDataAdapter, m_connection);
|
||||||
|
m_shapeDataAdapter.FillSchema(m_shapeTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_shapeDataAdapter.Fill(m_shapeTable);
|
m_shapeDataAdapter.Fill(m_shapeTable);
|
||||||
|
|
||||||
if (persistPrimInventories)
|
if (persistPrimInventories)
|
||||||
|
@ -120,22 +122,26 @@ namespace OpenSim.Framework.Data.MySQL
|
||||||
m_itemsTable = createItemsTable();
|
m_itemsTable = createItemsTable();
|
||||||
m_dataSet.Tables.Add(m_itemsTable);
|
m_dataSet.Tables.Add(m_itemsTable);
|
||||||
SetupItemsCommands(m_itemsDataAdapter, m_connection);
|
SetupItemsCommands(m_itemsDataAdapter, m_connection);
|
||||||
|
m_itemsDataAdapter.FillSchema(m_itemsTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_itemsDataAdapter.Fill(m_itemsTable);
|
m_itemsDataAdapter.Fill(m_itemsTable);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_terrainTable = createTerrainTable();
|
m_terrainTable = createTerrainTable();
|
||||||
m_dataSet.Tables.Add(m_terrainTable);
|
m_dataSet.Tables.Add(m_terrainTable);
|
||||||
SetupTerrainCommands(m_terrainDataAdapter, m_connection);
|
SetupTerrainCommands(m_terrainDataAdapter, m_connection);
|
||||||
|
m_terrainDataAdapter.FillSchema(m_terrainTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_terrainDataAdapter.Fill(m_terrainTable);
|
m_terrainDataAdapter.Fill(m_terrainTable);
|
||||||
|
|
||||||
m_landTable = createLandTable();
|
m_landTable = createLandTable();
|
||||||
m_dataSet.Tables.Add(m_landTable);
|
m_dataSet.Tables.Add(m_landTable);
|
||||||
setupLandCommands(m_landDataAdapter, m_connection);
|
setupLandCommands(m_landDataAdapter, m_connection);
|
||||||
|
m_landDataAdapter.FillSchema(m_landTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_landDataAdapter.Fill(m_landTable);
|
m_landDataAdapter.Fill(m_landTable);
|
||||||
|
|
||||||
m_landAccessListTable = createLandAccessListTable();
|
m_landAccessListTable = createLandAccessListTable();
|
||||||
m_dataSet.Tables.Add(m_landAccessListTable);
|
m_dataSet.Tables.Add(m_landAccessListTable);
|
||||||
setupLandAccessCommands(m_landAccessListDataAdapter, m_connection);
|
setupLandAccessCommands(m_landAccessListDataAdapter, m_connection);
|
||||||
|
m_landAccessListDataAdapter.FillSchema(m_landAccessListTable, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
m_landAccessListDataAdapter.Fill(m_landAccessListTable);
|
m_landAccessListDataAdapter.Fill(m_landAccessListTable);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1581,14 +1587,22 @@ namespace OpenSim.Framework.Data.MySQL
|
||||||
DataSet tmpDS = new DataSet();
|
DataSet tmpDS = new DataSet();
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
pDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
pDa.Fill(tmpDS, "prims");
|
pDa.Fill(tmpDS, "prims");
|
||||||
|
sDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
sDa.Fill(tmpDS, "primshapes");
|
sDa.Fill(tmpDS, "primshapes");
|
||||||
|
|
||||||
if (persistPrimInventories)
|
if (persistPrimInventories)
|
||||||
|
{
|
||||||
|
iDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
iDa.Fill(tmpDS, "primitems");
|
iDa.Fill(tmpDS, "primitems");
|
||||||
|
}
|
||||||
|
|
||||||
|
tDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
tDa.Fill(tmpDS, "terrain");
|
tDa.Fill(tmpDS, "terrain");
|
||||||
|
lDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
lDa.Fill(tmpDS, "land");
|
lDa.Fill(tmpDS, "land");
|
||||||
|
lalDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
lalDa.Fill(tmpDS, "landaccesslist");
|
lalDa.Fill(tmpDS, "landaccesslist");
|
||||||
}
|
}
|
||||||
catch (MySqlException)
|
catch (MySqlException)
|
||||||
|
@ -1597,14 +1611,22 @@ namespace OpenSim.Framework.Data.MySQL
|
||||||
InitDB(conn);
|
InitDB(conn);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
pDa.Fill(tmpDS, "prims");
|
pDa.Fill(tmpDS, "prims");
|
||||||
|
sDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
sDa.Fill(tmpDS, "primshapes");
|
sDa.Fill(tmpDS, "primshapes");
|
||||||
|
|
||||||
if (persistPrimInventories)
|
if (persistPrimInventories)
|
||||||
|
{
|
||||||
|
iDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
iDa.Fill(tmpDS, "primitems");
|
iDa.Fill(tmpDS, "primitems");
|
||||||
|
}
|
||||||
|
|
||||||
|
tDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
tDa.Fill(tmpDS, "terrain");
|
tDa.Fill(tmpDS, "terrain");
|
||||||
|
lDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
lDa.Fill(tmpDS, "land");
|
lDa.Fill(tmpDS, "land");
|
||||||
|
lalDa.FillSchema(tmpDS, SchemaType.Source); // to avoid random System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
|
||||||
lalDa.Fill(tmpDS, "landaccesslist");
|
lalDa.Fill(tmpDS, "landaccesslist");
|
||||||
|
|
||||||
foreach (DataColumn col in createPrimTable().Columns)
|
foreach (DataColumn col in createPrimTable().Columns)
|
||||||
|
|
Loading…
Reference in New Issue