Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Bugs with the database

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Bugs with the database

    Problems with the database.

    I had a problem with the database and tried to Reset it.


    Here is the trace that I got :

    2009-10-15 22:26:08:830 in OnUnhandledThreadException
    2009-10-15 22:26:08:971 ********* exception trapped *********
    2009-10-15 22:26:08:971 The primary key value cannot be deleted because references to this key still exist. [ Foreign key constraint name = FK__nt_strategy2strategy__00000000000002D4 ]
    2009-10-15 22:26:08:971 at System.Data.SqlServerCe.SqlCeCommand.ProcessResult s(Int32 hr)
    at System.Data.SqlServerCe.SqlCeCommand.ExecuteComman dText(IntPtr& pCursor, Boolean& isBaseTableCursor)
    at System.Data.SqlServerCe.SqlCeCommand.ExecuteComman d(CommandBehavior behavior, String method, ResultSetOptions options)
    at System.Data.SqlServerCe.SqlCeCommand.ExecuteNonQue ry()
    at Wilson.ORMapper.Internals.Connection.ExecuteComman d(Type entityType, CommandInfo commandInfo, String sqlStatement, Parameter[] parameters)
    at Wilson.ORMapper.ObjectSpace.ExecuteDelete(Type objectType, String whereClause)
    at NinjaTrader.Gui.OptionsForm.OnResetDB(Object sender, EventArgs e)
    at System.Windows.Forms.Control.OnClick(EventArgs e)
    at System.Windows.Forms.Button.OnClick(EventArgs e)
    at System.Windows.Forms.Button.OnMouseUp(MouseEventAr gs mevent)
    at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
    at System.Windows.Forms.Control.WndProc(Message& m)
    at System.Windows.Forms.ButtonBase.WndProc(Message& m)
    at System.Windows.Forms.Button.WndProc(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.O nMessage(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.W ndProc(Message& m)
    at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

    #2
    To clarify: you got that trace as you tried to repair the DB? So it was not your original problem?

    If so, the please mail me your zipped DB to "dierk AT ninjatrader DOT com". Thanks

    Comment


      #3
      Dierk


      what I did is that I put a print statement in a strategy that was way too big which froze NT.

      I had to shut it down.
      After that I repair the DB, worked well but the strategies were working in a strange way. I was not getting the same result after than before.

      So I tried to reset the DB and this is when I got the ugly error message from NT...


      Bernard

      Comment


        #4
        Got it. Please send me the zipped DB file <my documents>/NinjaTrader 7/db/NinjaTrader.sdf as per below. Thanks

        Comment


          #5
          Dierk

          I will....

          Thanks

          Bernard

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          627 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          359 views
          1 like
          Last Post Geovanny Suaza  
          Started by Mindset, 02-09-2026, 11:44 AM
          0 responses
          105 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by Geovanny Suaza, 02-02-2026, 12:30 PM
          0 responses
          562 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          567 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X