when a new object is created in my database, and then I query the table from the datacontext, the new object does not appear. Does linq cache the table and return the cached version? if so, how can I stop linq from doing this.
DALConnector.Dc.Order.InsertOnSubmit(NewOrder); DALConnector.Dc.SubmitChanges();
now I press a button that shows a form with a gridview on it databound on a DALConnector.Dc.Order that does not show the new order
? , , . , ... , (, ), ensurihg, Orders , .
, :
grid.DataSource = customer.Orders;
customer.Orders.Add(newOrder); dc.Orders.InsertOnSubmit(newOrder); dc.SubmitChanges();
. .
Linq2Sql DataContext , - . DataContext , , , , .
DataContext
Linq2Sql, SQL Server, SQL Server , .
dbml, runtime insert Order?
Order
, - , DataContext SubmitChanges().
SubmitChanges()
, , .
Source: https://habr.com/ru/post/1728723/More articles:save / edit array inside and outside ruby - ruby | fooobar.comThe image of the watermark on the camera screen is offset - objective-cPython ds import math module - pythonDjango: chicken or egg question - pythonhorizontal scrollbar issue in list and tree component - flexUsing Camera on iPad / iPhone Overlay - iosHow to add an overlay view to the camera and save it - objective-cHow can I remove a warning warning in java? - javaNamespace and assembly names for reusable component - c #Duplicate value in postgresql table - sqlAll Articles