[MonetDB-users] protocol violation Unexpected line in data block

Hi All, When i try to fetch data from a table some times i am getting this error: It seems it has some thing to do with the type of characters that are being inserted. I am wondering why it didn't threw any exception while inserting but throwing the excep when trying to retrieve !! I hope this is not because of the sql client i am using..I tried using Squrriel and QuantumDB plugin of Eclipse. Here is the Stack Trace Error Executing: select * from dpa.collection_info:java.sql.SQLException: protocol violation: unexpected line in data block: . java.sql.SQLException: protocol violation: unexpected line in data block: . at nl.cwi.monetdb.jdbc.MonetConnection$ResponseList.executeQuery(MonetConnection.java:2048) at nl.cwi.monetdb.jdbc.MonetConnection$ResponseList.processQuery(MonetConnection.java:1798) at nl.cwi.monetdb.jdbc.MonetStatement.internalExecute(MonetStatement.java:371) at nl.cwi.monetdb.jdbc.MonetStatement.execute(MonetStatement.java:340) at sun.reflect.GeneratedMethodAccessor26.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.quantum.util.proxy.ProxyFactory$InvocationHandlerImpl.invoke(ProxyFactory.java:37) at $Proxy4.execute(Unknown Source) at com.quantum.sql.MultiSQLServer.execute(MultiSQLServer.java:133) at com.quantum.sql.MultiSQLServer.execute(MultiSQLServer.java:91) at com.quantum.actions.BaseExecuteAction.getSQLResults(BaseExecuteAction.java:202) at com.quantum.actions.BaseExecuteAction.execute(BaseExecuteAction.java:174) at com.quantum.actions.ExecuteAction.execute(ExecuteAction.java:98) at com.quantum.actions.BaseExecuteAction.execute(BaseExecuteAction.java:125) at com.quantum.actions.BaseExecuteAction.run(BaseExecuteAction.java:111) at org.eclipse.ui.actions.BaseSelectionListenerAction.runWithEvent(BaseSelectionListenerAction.java:168) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490) at org.eclipse.jface.action.ActionContributionItem$6.handleEvent(ActionContributionItem.java:443) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1101) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3319) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2971) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219) at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:153) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:504) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:443) at org.eclipse.equinox.launcher.Main.run(Main.java:1169) -- View this message in context: http://www.nabble.com/protocol-violation-Unexpected-line-in-data-block-tp153... Sent from the monetdb-users mailing list archive at Nabble.com.

On 08-02-2008 12:41:56 -0800, sateesh wrote:
Hi All,
When i try to fetch data from a table some times i am getting this error:
It seems it has some thing to do with the type of characters that are being inserted.
I am wondering why it didn't threw any exception while inserting but throwing the excep when trying to retrieve !!
I hope this is not because of the sql client i am using..I tried using Squrriel and QuantumDB plugin of Eclipse.
Here is the Stack Trace
Error Executing: select * from dpa.collection_info:java.sql.SQLException: protocol violation: unexpected line in data block: . java.sql.SQLException: protocol violation: unexpected line in data block: .
Could you please add ?debug=true to your JDBC connection URL, and then attach the monet_125324563278468723.log?

Hi Fabian, I tried running the same query programmatically and it returned the results with out any problems. And there are no special characters in the data..I tried running the query using ?debug=true and with out this and both ran fine. I am not sure why the SQL Clients are complaining.. In SLQ Client setting i have added the ?debug=true and here is the stack trace.. java.sql.SQLException: Method not implemented yet, sorry! at nl.cwi.monetdb.jdbc.MonetResultSet.getCharacterStream(MonetResultSet.java:294) at sun.reflect.GeneratedMethodAccessor35.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.quantum.util.proxy.ProxyFactory$InvocationHandlerImpl.invoke(ProxyFactory.java:37) at $Proxy3.getCharacterStream(Unknown Source) at com.quantum.sql.SQLStandardResultSetResults.getStringFromCharacterSteam(SQLStandardResultSetResults.java:250) at com.quantum.sql.SQLStandardResultSetResults.parseResultSet(SQLStandardResultSetResults.java:147) at com.quantum.sql.SQLStandardResultSetResults.create(SQLStandardResultSetResults.java:69) at com.quantum.sql.MultiSQLServer.execute(MultiSQLServer.java:139) at com.quantum.sql.MultiSQLServer.execute(MultiSQLServer.java:91) at com.quantum.actions.BaseExecuteAction.getSQLResults(BaseExecuteAction.java:202) at com.quantum.actions.BaseExecuteAction.execute(BaseExecuteAction.java:174) at com.quantum.actions.ExecuteAction.execute(ExecuteAction.java:98) at com.quantum.actions.BaseExecuteAction.execute(BaseExecuteAction.java:125) at com.quantum.actions.BaseExecuteAction.run(BaseExecuteAction.java:111) at org.eclipse.ui.actions.BaseSelectionListenerAction.runWithEvent(BaseSelectionListenerAction.java:168) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490) at org.eclipse.jface.action.ActionContributionItem$6.handleEvent(ActionContributionItem.java:443) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1101) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3319) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2971) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219) at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:153) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:504) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:443) at org.eclipse.equinox.launcher.Main.run(Main.java:1169) thanks sateesh Fabian Groffen wrote:
On 08-02-2008 12:41:56 -0800, sateesh wrote:
Hi All,
When i try to fetch data from a table some times i am getting this error:
It seems it has some thing to do with the type of characters that are being inserted.
I am wondering why it didn't threw any exception while inserting but throwing the excep when trying to retrieve !!
I hope this is not because of the sql client i am using..I tried using Squrriel and QuantumDB plugin of Eclipse.
Here is the Stack Trace
Error Executing: select * from dpa.collection_info:java.sql.SQLException: protocol violation: unexpected line in data block: . java.sql.SQLException: protocol violation: unexpected line in data block: .
Could you please add ?debug=true to your JDBC connection URL, and then attach the monet_125324563278468723.log?
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- View this message in context: http://www.nabble.com/protocol-violation-Unexpected-line-in-data-block-tp153... Sent from the monetdb-users mailing list archive at Nabble.com.

On 08-02-2008 13:09:38 -0800, sateesh wrote:
Hi Fabian,
I tried running the same query programmatically and it returned the results with out any problems.
And there are no special characters in the data..I tried running the query using ?debug=true and with out this and both ran fine.
I am not sure why the SQL Clients are complaining..
In SLQ Client setting i have added the ?debug=true and here is the stack trace..
If you use debug=true, a logfile is created. Its contents show why what goes wrong (more or less). The file is somewhere in the working directory, called monet_29821371983278192.log I need to see that file to say who or what is wrong for your case.

Here i am attaching the log file.. http://www.nabble.com/file/p15419123/monet_1202504894784.log monet_1202504894784.log -- View this message in context: http://www.nabble.com/protocol-violation-Unexpected-line-in-data-block-tp153... Sent from the monetdb-users mailing list archive at Nabble.com.

On 11-02-2008 11:46:06 -0800, sateesh wrote:
Here i am attaching the log file.. http://www.nabble.com/file/p15419123/monet_1202504894784.log monet_1202504894784.log
I'm sorry, but does this log belong to the "Sorry not implemented!" exception, or to the "Protocol violation!" exception? I think this one belongs to the "not implemented" one, which is a feature request. Your original message indicated a bug, which I'd like to examine more closely.

This is the log file we receive when attempting to display the contents of tables using Squirrel SQL, or any number of other clients using the JDBC driver. The error message is Error: protocol violation: unexpected line in data block: In one of the columns, for some INSERTs we store bytes and for other INSERTs, into the same column, we store characters. The column is of type VARCHAR. Is this the issue? Thanks On Monday 11 February 2008 14:51:42 Fabian Groffen wrote:
On 11-02-2008 11:46:06 -0800, sateesh wrote:
Here i am attaching the log file.. http://www.nabble.com/file/p15419123/monet_1202504894784.log monet_1202504894784.log
I'm sorry, but does this log belong to the "Sorry not implemented!" exception, or to the "Protocol violation!" exception? I think this one belongs to the "not implemented" one, which is a feature request. Your original message indicated a bug, which I'd like to examine more closely.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users

On 11-02-2008 15:14:02 -0500, McKennirey.Matthew wrote:
This is the log file we receive when attempting to display the contents of tables using Squirrel SQL, or any number of other clients using the JDBC driver.
The error message is Error: protocol violation: unexpected line in data block:
In one of the columns, for some INSERTs we store bytes and for other INSERTs, into the same column, we store characters. The column is of type VARCHAR. Is this the issue?
No idea, I think I found your issue though: (removed lots of data to make it readable)
RX 1202760166421: &1 8 37 14 37 % # table_name % # name % # type % # length [ 1 [ 2 [ 3 [ 4 [ 5 [ 6 [ 7 [ 8 [ 9 [ 10 [ 11 [ 12 [ 13 [ 14 [ 15 [ 16
RD 1202760166421: inserting prompt
16 != (14 or 37) so JDBC gets confused by getting more rows than it expects. It could be clearer here in the error message, but I'm not sure where it ends up here, it might complain about seeing the prompt after reading line 15 and 16, in which case the error message is correct. Niels, any idea on how this can happen (sending more rows than the header says)? PS. This is a BUG.

On Mon, Feb 11, 2008 at 10:14:53PM +0100, Fabian Groffen wrote:
On 11-02-2008 15:14:02 -0500, McKennirey.Matthew wrote:
This is the log file we receive when attempting to display the contents of tables using Squirrel SQL, or any number of other clients using the JDBC driver.
The error message is Error: protocol violation: unexpected line in data block:
In one of the columns, for some INSERTs we store bytes and for other INSERTs, into the same column, we store characters. The column is of type VARCHAR. Is this the issue?
No idea, I think I found your issue though: (removed lots of data to make it readable)
RX 1202760166421: &1 8 37 14 37 % # table_name % # name % # type % # length [ 1 [ 2 [ 3 [ 4 [ 5 [ 6 [ 7 [ 8 [ 9 [ 10 [ 11 [ 12 [ 13 [ 14 [ 15 [ 16
RD 1202760166421: inserting prompt
16 != (14 or 37) so JDBC gets confused by getting more rows than it expects. It could be clearer here in the error message, but I'm not sure where it ends up here, it might complain about seeing the prompt after reading line 15 and 16, in which case the error message is correct.
Niels, any idea on how this can happen (sending more rows than the header says)? I have no idea. What is the query which gives this problematic output.
Niels
PS. This is a BUG.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- Niels Nes, Centre for Mathematics and Computer Science (CWI) Kruislaan 413, 1098 SJ Amsterdam, The Netherlands room C0.02, phone ++31 20 592-4098, fax ++31 20 592-4312 url: http://www.cwi.nl/~niels e-mail: Niels.Nes@cwi.nl

The error is reported by SQL clients (Squirrel SQL, OpenOffice, etc) when issuing SELECT * FROM "dpa"."collection_info"; The previous log file was the output when the above query was passed by the client. On Monday 11 February 2008 16:45:14 Niels Nes wrote:
On Mon, Feb 11, 2008 at 10:14:53PM +0100, Fabian Groffen wrote:
On 11-02-2008 15:14:02 -0500, McKennirey.Matthew wrote:
This is the log file we receive when attempting to display the contents of tables using Squirrel SQL, or any number of other clients using the JDBC driver.
The error message is Error: protocol violation: unexpected line in data block:
In one of the columns, for some INSERTs we store bytes and for other INSERTs, into the same column, we store characters. The column is of type VARCHAR. Is this the issue?
No idea, I think I found your issue though: (removed lots of data to make it readable)
RX 1202760166421: &1 8 37 14 37 % # table_name % # name % # type % # length [ 1 [ 2 [ 3 [ 4 [ 5 [ 6 [ 7 [ 8 [ 9 [ 10 [ 11 [ 12 [ 13 [ 14 [ 15 [ 16
RD 1202760166421: inserting prompt
16 != (14 or 37) so JDBC gets confused by getting more rows than it expects. It could be clearer here in the error message, but I'm not sure where it ends up here, it might complain about seeing the prompt after reading line 15 and 16, in which case the error message is correct.
Niels, any idea on how this can happen (sending more rows than the header says)?
I have no idea. What is the query which gives this problematic output.
Niels
PS. This is a BUG.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users

On 11-02-2008 16:57:03 -0500, McKennirey.Matthew wrote:
The error is reported by SQL clients (Squirrel SQL, OpenOffice, etc) when issuing
SELECT * FROM "dpa"."collection_info";
The previous log file was the output when the above query was passed by the client.
Indeed, the last query was TD 1202760166418: write final block: 35 bytes TX 1202760166418: sselect * from dpa.collection_info; RD 1202760166420: read final block: 4693 bytes RX 1202760166421: &1 8 37 14 37
No idea, I think I found your issue though: (removed lots of data to make it readable)
RX 1202760166421: &1 8 37 14 37 % # table_name % # name % # type % # length [ 1 [ 2 [ 3 [ 4 [ 5 [ 6 [ 7 [ 8 [ 9 [ 10 [ 11 [ 12 [ 13 [ 14 [ 15 [ 16
RD 1202760166421: inserting prompt
16 != (14 or 37) so JDBC gets confused by getting more rows than it expects. It could be clearer here in the error message, but I'm not sure where it ends up here, it might complain about seeing the prompt after reading line 15 and 16, in which case the error message is correct.
Niels, any idea on how this can happen (sending more rows than the header says)?
I have no idea. What is the query which gives this problematic output.
Niels
PS. This is a BUG.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users

On Tue, Feb 19, 2008 at 01:39:02PM +0100, Fabian Groffen wrote:
On 11-02-2008 16:57:03 -0500, McKennirey.Matthew wrote:
I just need all the queries and data to repeat this (in a simple script and or sql file). Only then I can try to fix the problem. Niels
The error is reported by SQL clients (Squirrel SQL, OpenOffice, etc) when issuing
SELECT * FROM "dpa"."collection_info";
The previous log file was the output when the above query was passed by the client.
Indeed, the last query was
TD 1202760166418: write final block: 35 bytes TX 1202760166418: sselect * from dpa.collection_info; RD 1202760166420: read final block: 4693 bytes RX 1202760166421: &1 8 37 14 37
No idea, I think I found your issue though: (removed lots of data to make it readable)
RX 1202760166421: &1 8 37 14 37 % # table_name % # name % # type % # length [ 1 [ 2 [ 3 [ 4 [ 5 [ 6 [ 7 [ 8 [ 9 [ 10 [ 11 [ 12 [ 13 [ 14 [ 15 [ 16
RD 1202760166421: inserting prompt
16 != (14 or 37) so JDBC gets confused by getting more rows than it expects. It could be clearer here in the error message, but I'm not sure where it ends up here, it might complain about seeing the prompt after reading line 15 and 16, in which case the error message is correct.
Niels, any idea on how this can happen (sending more rows than the header says)?
I have no idea. What is the query which gives this problematic output.
Niels
PS. This is a BUG.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- Niels Nes, Centre for Mathematics and Computer Science (CWI) Kruislaan 413, 1098 SJ Amsterdam, The Netherlands room C0.02, phone ++31 20 592-4098, fax ++31 20 592-4312 url: http://www.cwi.nl/~niels e-mail: Niels.Nes@cwi.nl
participants (4)
-
Fabian Groffen
-
McKennirey.Matthew
-
Niels Nes
-
sateesh