Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. COThis was not the problem in my case. I really tracked it down to the problem that at one point the value of @@TRANCOUNT was taken from the cache where it should have selected it from the database (see my own response above). So it returned 0 where it should have been 1, and as a consequence a transaction was not committed.
      singulars
    2. COThis <code>CACHE (0.0ms) SELECT @@TRANCOUNT</code> should never happen. The 2.3 adapter codebase uses the #info_schema_query helper does not do what it really should. In the 2-3-stable branch, it is concerned with logging. To see what I mean, take a look at the latest 3-2-stable/master code. There is a changelog that mentions how we now properly use the `SCHEMA` name argument in DB queries that are for reflection and schema related. This means they are not cached also. So... if you wanted to patch the 2-3-stable branch, maybe something like this https://gist.github.com/metaskills/5387936
      singulars
    3. COThanks for your comment! I have tried adding the "SCHEMA" argument. With the first call, the log (I locally changed the code that is supressing the logging for this) is now showing `SCHEMA (0.5ms) SELECT @@TRANCOUNT`. But the second time I still get the `CACHE (0.0ms) SELECT @@TRANCOUNT` line, and the error occurs again (maybe the SCHEMA thing is Rails 3.x specific?). I have now tried changing the line to `trancount = uncached { select_value("SELECT @@TRANCOUNT") }`, which seems to fix the problem.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload