473,378 Members | 1,721 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Error 11 (can't unlock file) in different places for sp vs script

m
Hi,
I'm running MySQL (5.0.18-nt) on WinXP with latest patches.

I've some SQL code that generates an 'ERROR 11' in two different places
depending on how the code is submitted.
At the moment I'de like to find out what is causing the error, so I
haven't included the code, which is quite lengthy.

I'm not a MySQL (or anyother db) expert, but I've turned on isam
logging and run the myisamlog utility which didn't seem to be the right
tool...?

I'd like to know how I can find out what is causing this error. Any
suggestions appreciated.

If submitted via:
mysql -u root -e "SOURCE "./../SQL/code.sql";"

the error occurs in the _third_ 'part' of the script (line 131 referred
to is between an insert and a select statement). the error message is:

ERROR 11 (HY000) at line 131 in file: 'D:\MySQL\SQL\code.sql': Can't
unlock file (Errcode: 11)

If submitted via:
mysql -u root -e "CALL `taq`.`sp_code`();"

the error occurs in the _first_ 'part' of the script. the error
message is:

ERROR 11 (HY000) at line 1: Can't unlock file (Errcode: 11)

Feb 16 '06 #1
3 2440
"m" <mv****@gmail.com> wrote in message
news:11*********************@g44g2000cwa.googlegro ups.com...
I'd like to know how I can find out what is causing this error. Any
suggestions appreciated.

ERROR 11 (HY000) at line 131 in file: 'D:\MySQL\SQL\code.sql': Can't
unlock file (Errcode: 11)


Well, since you don't describe the database schema, activity on the server,
or the statements that are executing when you get this error, there's not
much to go on here...

My usual first step in diagnosing an error I haven't seen before is a Google
search for search terms containing the error. Sometimes I can get clues
from past discussions about the same symptoms. For example, search Google
for:

mysql "can't unlock file" "error 11"

This search reveals a number of pages with MySQL bug reports and past MySQL
list traffic on this topic, mostly the resolution is that the user was
running myisamchk while MySQL service is running.

Regards,
Bill K.
Feb 16 '06 #2
m
Hi Bill,
Thanks for your response. I had done as you suggest and had ruled out
the 'server running explanation.
I get this error from the mysql server (rather than myisamchk) and in
two different ways from the same code depending on whether it is run
via a stored procedure or as a script.

Good to know there was some other 'obvious' tool/technique I had over
looked.
Cheers
Mark

Feb 17 '06 #3
m
I have a two SQL files that contain example scripts that should
generate the behavior I refer to. One script contains some data and is
160K, the other about 300bytes.
If anyone is interested in receiving these let me know and I'll email
them.

The show warnings indicates the Errcode 11: is not all that is going
wrong:

The SHOW WARNINGS; statement produces the following:
+---------+------+---------------------------------------------------------------+
| Level | Code | Message
|
+---------+------+---------------------------------------------------------------+
| Error | 11 | Can't unlock file (Errcode: 11)
|
| Error | 1105 | Unknown error
|
| Warning | 1196 | Some non-transactional changed tables couldn't
be rolled back|
+---------+------+---------------------------------------------------------------+

Regards
Mark

Feb 17 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Wayno | last post by:
My php logs are coming up empty. I have done all I can think of, and all that made sense to me. Can someone take a look at my php.ini please and tell me what you think may be the problem. I...
2
by: Chuck Martin | last post by:
I am having a most frustrating problem that references, web searches, and other resources are no help so far in solving. Basically, I'm trying to design a pop-up window to be called with a funciton...
9
by: JTrigger | last post by:
When I compile my project using the IDE on a development machine it works just fine. When I compile it on the server using csc.exe, I get the following error when I try to bring it up in the web...
10
by: robwharram | last post by:
Hi, I'm quite frustrated in the fact that I can't even display a simple "Hello World" message on .Net. I've been through all of the groups and searched all over the place and haven't been able...
8
by: jcrouse | last post by:
I am using the following code to trap errors in a sub routine: Try Executable code Catch ex As Exception Dim strInputE As String = Application.StartupPath & "\Error.txt" Dim srE As...
4
by: Kiyomi | last post by:
Hello, I am trying to replace my alert message box with a popup page. In my page behind,
39
by: eruanion | last post by:
Hi, I've been working on this for a while now and I can't seem to find out what is wrong with my code. I have 2 files one c3common.js which only contains javascript functions for my main html page...
0
by: mschvili | last post by:
I try to control the number of how many users are on the site at the moment. To do so I have use the global.asax like this: <%@ Page Language="VB" ContentType="text/html"...
1
by: mudasserrafiq | last post by:
I am using following asp file default.asp <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <META http-equiv=Content-Type content="text/html; charset=windows-1252"> <META content="0...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.