Search found 15 matches

by EeeeEfff
Wed 15 Feb 2012 13:11
Forum: dotConnect for Cloud Applications
Topic: "You have an error in your SQL syntax" message
Replies: 3
Views: 24200

Duh! Should have thought of that. Thanks for the explanation.
by EeeeEfff
Sun 12 Feb 2012 22:42
Forum: dotConnect for Cloud Applications
Topic: "You have an error in your SQL syntax" message
Replies: 3
Views: 24200

Figured it out. Any table or column that is not native to Salesforce.com or does not extend from an existing SF.com object needs to be quoted. So, in my example, when I changed my query to :

"SELECT * FROM \"Case\""

the query went through just fine.
by EeeeEfff
Sun 12 Feb 2012 22:28
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

So no matter what I do, I cannot get your sample to break, even mimicking the structures I have. The only thing I can think of is it must be table size related, because as soon as I point your sample at the real database, using my objects, it croaks about 60 rows into the IQueryable Enumerator... I am currently at a loss as to how to proceed.
by EeeeEfff
Fri 10 Feb 2012 23:54
Forum: dotConnect for Cloud Applications
Topic: "You have an error in your SQL syntax" message
Replies: 3
Views: 24200

"You have an error in your SQL syntax" message

Hi,
Using the snippet below from your sample project, the command fails with the error "You have an error in your SQL syntax at line 1, column 15: Unexpected symbol 'Case'." The full error stack is at the bottom.

But if I change the sql string to "SELECT * FROM Account", things go through just fine. Any limitation I'm not aware of?

Thanks!

Code: Select all

    static void DataReader() {

      const string sql = "SELECT * FROM Case";
      using (SalesforceConnection connection = new SalesforceConnection(ConnectionString)) {

        connection.Open();
        using (SalesforceCommand command = connection.CreateCommand()) {

          command.CommandText = sql;
          using (SalesforceDataReader reader = command.ExecuteReader()) {

            while (reader.Read()) {
              string name = reader.IsDBNull(0) ? null : reader.GetString(0);
              string phone = reader.IsDBNull(1) ? null : reader.GetString(1);
            }
          }
        }
      }
    }

Code: Select all

Devart.Data.Salesforce.SalesforceException was unhandled
  Message=You have an error in your SQL syntax at line 1, column 15: Unexpected symbol 'Case'.
  Source=Devart.Data.Salesforce
  ErrorCode=-2147467259
  Cause=Unexpected
  Code=-1
  StackTrace:
       at Devart.Data.Internal.Parser.j.a(String[] A_0, ab A_1)
       at Antlr.Runtime.j.c(ab A_0)
       at a.cy()
       at a.dy()
       at a.e9()
       at a.d2()
       at a.z()
       at a.h()
       at a.fh()
       at a.bk()
       at a.bd()
       at a.d7()
       at a.cv()
       at a.a()
       at Devart.Data.Internal.Parser.j.c(Boolean A_0)
       at Devart.Data.Salesforce.SalesforceCommand.GetStatement()
       at Devart.Data.Salesforce.SalesforceCommand.InternalPrepare(Boolean implicitPrepare, Int32 startRecord, Int32 maxRecords)
       at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior, Boolean nonQuery)
       at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior)
       at System.Data.Common.DbCommand.ExecuteReader(CommandBehavior behavior)
       at Devart.Data.Salesforce.SalesforceCommand.ExecuteReader()
       at ConsoleDemo.Program.DataReader() in C:\Program Files (x86)\Devart\dotConnect\Salesforce\Samples\Console\cs\Program.cs:line 37
       at ConsoleDemo.Program.Main(String[] args) in C:\Program Files (x86)\Devart\dotConnect\Salesforce\Samples\Console\cs\Program.cs:line 18
       at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
       at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()
  InnerException: 
[/color]
by EeeeEfff
Tue 07 Feb 2012 20:34
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

Nevermind - found it. Playing with it now to make it break like in my scenario. Thanks again.
by EeeeEfff
Tue 07 Feb 2012 20:16
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

Thanks! Can you please resend the project? I have not received it - and it is not in my junk mail folder, etc..
by EeeeEfff
Tue 07 Feb 2012 05:44
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

Any thoughts? Help would really be appreciated. I'm stuck here.

Or is there an example of how to page through data?

Thanks!
by EeeeEfff
Fri 03 Feb 2012 18:35
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

Data Types in table are: INT(11), DateTime, VarChar, and Text. The specific result set I am trying to iterate over actually returns ~4k rows, each containing a TEXT object that is ~4k ~4.5k characters in length.

I am running MySQL 5.0.51a-3ubuntu5.8.

Variables is use are below, and the max_allowed_packet size is 16776192. That's about 15MB. Is that limit per row, or per set? My result set is 4300 rows, ~275MB. Currently, I do the following:

IQueryable match = _context.Metrics.Where(c => (c.Name.Equals(kpi.MetricName)));

And I loop over the IQueryable result set in a foreach loop.

That IQueryable result set is the large problematic one. Is there a recommended way to page/loop through a set like that?

Thanks!

Code: Select all

=======================================================================================================
|                  Variable_name                   |                      Value                       |
=======================================================================================================
|             auto_increment_increment             |                        1                         |
-------------------------------------------------------------------------------------------------------
|              auto_increment_offset               |                        1                         |
-------------------------------------------------------------------------------------------------------
|             automatic_sp_privileges              |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                     back_log                     |                        50                        |
-------------------------------------------------------------------------------------------------------
|                     basedir                      |                      /usr/                       |
-------------------------------------------------------------------------------------------------------
|                binlog_cache_size                 |                      32768                       |
-------------------------------------------------------------------------------------------------------
|             bulk_insert_buffer_size              |                     8388608                      |
-------------------------------------------------------------------------------------------------------
|               character_set_client               |                       utf8                       |
-------------------------------------------------------------------------------------------------------
|             character_set_connection             |                       utf8                       |
-------------------------------------------------------------------------------------------------------
|              character_set_database              |                       utf8                       |
-------------------------------------------------------------------------------------------------------
|             character_set_filesystem             |                      binary                      |
-------------------------------------------------------------------------------------------------------
|              character_set_results               |                       utf8                       |
-------------------------------------------------------------------------------------------------------
|               character_set_server               |                      latin1                      |
-------------------------------------------------------------------------------------------------------
|               character_set_system               |                       utf8                       |
-------------------------------------------------------------------------------------------------------
|                character_sets_dir                |            /usr/share/mysql/charsets/            |
-------------------------------------------------------------------------------------------------------
|               collation_connection               |                 utf8_general_ci                  |
-------------------------------------------------------------------------------------------------------
|                collation_database                |                 utf8_general_ci                  |
-------------------------------------------------------------------------------------------------------
|                 collation_server                 |                latin1_swedish_ci                 |
-------------------------------------------------------------------------------------------------------
|                 completion_type                  |                        0                         |
-------------------------------------------------------------------------------------------------------
|                concurrent_insert                 |                        1                         |
-------------------------------------------------------------------------------------------------------
|                 connect_timeout                  |                       300                        |
-------------------------------------------------------------------------------------------------------
|                     datadir                      |                 /var/lib/mysql/                  |
-------------------------------------------------------------------------------------------------------
|                   date_format                    |                     %Y-%m-%d                     |
-------------------------------------------------------------------------------------------------------
|                 datetime_format                  |                %Y-%m-%d %H:%i:%s                 |
-------------------------------------------------------------------------------------------------------
|               default_week_format                |                        0                         |
-------------------------------------------------------------------------------------------------------
|                 delay_key_write                  |                        ON                        |
-------------------------------------------------------------------------------------------------------
|               delayed_insert_limit               |                       100                        |
-------------------------------------------------------------------------------------------------------
|              delayed_insert_timeout              |                       300                        |
-------------------------------------------------------------------------------------------------------
|                delayed_queue_size                |                       1000                       |
-------------------------------------------------------------------------------------------------------
|             div_precision_increment              |                        4                         |
-------------------------------------------------------------------------------------------------------
|               keep_files_on_create               |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|            engine_condition_pushdown             |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                 expire_logs_days                 |                        10                        |
-------------------------------------------------------------------------------------------------------
|                      flush                       |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                    flush_time                    |                        0                         |
-------------------------------------------------------------------------------------------------------
|                ft_boolean_syntax                 |                  + -><()~*:""&|                  |
-------------------------------------------------------------------------------------------------------
|                 ft_max_word_len                  |                        84                        |
-------------------------------------------------------------------------------------------------------
|                 ft_min_word_len                  |                        4                         |
-------------------------------------------------------------------------------------------------------
|             ft_query_expansion_limit             |                        20                        |
-------------------------------------------------------------------------------------------------------
|                 ft_stopword_file                 |                    (built-in)                    |
-------------------------------------------------------------------------------------------------------
|               group_concat_max_len               |                       1024                       |
-------------------------------------------------------------------------------------------------------
|                   have_archive                   |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                     have_bdb                     |                        NO                        |
-------------------------------------------------------------------------------------------------------
|              have_blackhole_engine               |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                  have_compress                   |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                    have_crypt                    |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                     have_csv                     |                       YES                        |
-------------------------------------------------------------------------------------------------------
|               have_dynamic_loading               |                       YES                        |
-------------------------------------------------------------------------------------------------------
|               have_example_engine                |                        NO                        |
-------------------------------------------------------------------------------------------------------
|              have_federated_engine               |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                  have_geometry                   |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                   have_innodb                    |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                    have_isam                     |                        NO                        |
-------------------------------------------------------------------------------------------------------
|                have_merge_engine                 |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                 have_ndbcluster                  |                     DISABLED                     |
-------------------------------------------------------------------------------------------------------
|                   have_openssl                   |                     DISABLED                     |
-------------------------------------------------------------------------------------------------------
|                     have_ssl                     |                     DISABLED                     |
-------------------------------------------------------------------------------------------------------
|                 have_query_cache                 |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                    have_raid                     |                        NO                        |
-------------------------------------------------------------------------------------------------------
|                 have_rtree_keys                  |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                   have_symlink                   |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                     hostname                     |                  coverity-lnx01                  |
-------------------------------------------------------------------------------------------------------
|                   init_connect                   |                                                  |
-------------------------------------------------------------------------------------------------------
|                    init_file                     |                                                  |
-------------------------------------------------------------------------------------------------------
|                    init_slave                    |                                                  |
-------------------------------------------------------------------------------------------------------
|         innodb_additional_mem_pool_size          |                     1048576                      |
-------------------------------------------------------------------------------------------------------
|           innodb_autoextend_increment            |                        8                         |
-------------------------------------------------------------------------------------------------------
|          innodb_buffer_pool_awe_mem_mb           |                        0                         |
-------------------------------------------------------------------------------------------------------
|             innodb_buffer_pool_size              |                     8388608                      |
-------------------------------------------------------------------------------------------------------
|                 innodb_checksums                 |                        ON                        |
-------------------------------------------------------------------------------------------------------
|            innodb_commit_concurrency             |                        0                         |
-------------------------------------------------------------------------------------------------------
|            innodb_concurrency_tickets            |                       500                        |
-------------------------------------------------------------------------------------------------------
|              innodb_data_file_path               |              ibdata1:10M:autoextend              |
-------------------------------------------------------------------------------------------------------
|               innodb_data_home_dir               |                                                  |
-------------------------------------------------------------------------------------------------------
|                innodb_doublewrite                |                        ON                        |
-------------------------------------------------------------------------------------------------------
|               innodb_fast_shutdown               |                        1                         |
-------------------------------------------------------------------------------------------------------
|              innodb_file_io_threads              |                        4                         |
-------------------------------------------------------------------------------------------------------
|              innodb_file_per_table               |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|          innodb_flush_log_at_trx_commit          |                        1                         |
-------------------------------------------------------------------------------------------------------
|               innodb_flush_method                |                                                  |
-------------------------------------------------------------------------------------------------------
|              innodb_force_recovery               |                        0                         |
-------------------------------------------------------------------------------------------------------
|             innodb_lock_wait_timeout             |                        50                        |
-------------------------------------------------------------------------------------------------------
|          innodb_locks_unsafe_for_binlog          |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|               innodb_log_arch_dir                |                                                  |
-------------------------------------------------------------------------------------------------------
|                innodb_log_archive                |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|              innodb_log_buffer_size              |                     1048576                      |
-------------------------------------------------------------------------------------------------------
|               innodb_log_file_size               |                     5242880                      |
-------------------------------------------------------------------------------------------------------
|            innodb_log_files_in_group             |                        2                         |
-------------------------------------------------------------------------------------------------------
|            innodb_log_group_home_dir             |                        ./                        |
-------------------------------------------------------------------------------------------------------
|            innodb_max_dirty_pages_pct            |                        90                        |
-------------------------------------------------------------------------------------------------------
|               innodb_max_purge_lag               |                        0                         |
-------------------------------------------------------------------------------------------------------
|            innodb_mirrored_log_groups            |                        1                         |
-------------------------------------------------------------------------------------------------------
|                innodb_open_files                 |                       300                        |
-------------------------------------------------------------------------------------------------------
|            innodb_rollback_on_timeout            |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                innodb_support_xa                 |                        ON                        |
-------------------------------------------------------------------------------------------------------
|              innodb_sync_spin_loops              |                        20                        |
-------------------------------------------------------------------------------------------------------
|                innodb_table_locks                |                        ON                        |
-------------------------------------------------------------------------------------------------------
|            innodb_thread_concurrency             |                        8                         |
-------------------------------------------------------------------------------------------------------
|            innodb_thread_sleep_delay             |                      10000                       |
-------------------------------------------------------------------------------------------------------
|               interactive_timeout                |                      28800                       |
-------------------------------------------------------------------------------------------------------
|                 join_buffer_size                 |                      131072                      |
-------------------------------------------------------------------------------------------------------
|                 key_buffer_size                  |                     16777216                     |
-------------------------------------------------------------------------------------------------------
|             key_cache_age_threshold              |                       300                        |
-------------------------------------------------------------------------------------------------------
|               key_cache_block_size               |                       1024                       |
-------------------------------------------------------------------------------------------------------
|             key_cache_division_limit             |                       100                        |
-------------------------------------------------------------------------------------------------------
|                     language                     |            /usr/share/mysql/english/             |
-------------------------------------------------------------------------------------------------------
|               large_files_support                |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                 large_page_size                  |                        0                         |
-------------------------------------------------------------------------------------------------------
|                   large_pages                    |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                  lc_time_names                   |                      en_US                       |
-------------------------------------------------------------------------------------------------------
|                     license                      |                       GPL                        |
-------------------------------------------------------------------------------------------------------
|                   local_infile                   |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                 locked_in_memory                 |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                       log                        |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                     log_bin                      |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|         log_bin_trust_function_creators          |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                    log_error                     |                                                  |
-------------------------------------------------------------------------------------------------------
|          log_queries_not_using_indexes           |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                log_slave_updates                 |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                 log_slow_queries                 |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                   log_warnings                   |                        1                         |
-------------------------------------------------------------------------------------------------------
|                 long_query_time                  |                        10                        |
-------------------------------------------------------------------------------------------------------
|               low_priority_updates               |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|              lower_case_file_system              |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|              lower_case_table_names              |                        0                         |
-------------------------------------------------------------------------------------------------------
|                max_allowed_packet                |                     16776192                     |
-------------------------------------------------------------------------------------------------------
|              max_binlog_cache_size               |               18446744073709551615               |
-------------------------------------------------------------------------------------------------------
|                 max_binlog_size                  |                    104857600                     |
-------------------------------------------------------------------------------------------------------
|                max_connect_errors                |                        10                        |
-------------------------------------------------------------------------------------------------------
|                 max_connections                  |                       100                        |
-------------------------------------------------------------------------------------------------------
|               max_delayed_threads                |                        20                        |
-------------------------------------------------------------------------------------------------------
|                 max_error_count                  |                        64                        |
-------------------------------------------------------------------------------------------------------
|               max_heap_table_size                |                     16777216                     |
-------------------------------------------------------------------------------------------------------
|            max_insert_delayed_threads            |                        20                        |
-------------------------------------------------------------------------------------------------------
|                  max_join_size                   |               18446744073709551615               |
-------------------------------------------------------------------------------------------------------
|             max_length_for_sort_data             |                       1024                       |
-------------------------------------------------------------------------------------------------------
|             max_prepared_stmt_count              |                      16382                       |
-------------------------------------------------------------------------------------------------------
|                max_relay_log_size                |                        0                         |
-------------------------------------------------------------------------------------------------------
|                max_seeks_for_key                 |               18446744073709551615               |
-------------------------------------------------------------------------------------------------------
|                 max_sort_length                  |                       1024                       |
-------------------------------------------------------------------------------------------------------
|              max_sp_recursion_depth              |                        0                         |
-------------------------------------------------------------------------------------------------------
|                  max_tmp_tables                  |                        32                        |
-------------------------------------------------------------------------------------------------------
|               max_user_connections               |                        0                         |
-------------------------------------------------------------------------------------------------------
|               max_write_lock_count               |               18446744073709551615               |
-------------------------------------------------------------------------------------------------------
|                multi_range_count                 |                       256                        |
-------------------------------------------------------------------------------------------------------
|             myisam_data_pointer_size             |                        6                         |
-------------------------------------------------------------------------------------------------------
|            myisam_max_sort_file_size             |               9223372036854775807                |
-------------------------------------------------------------------------------------------------------
|              myisam_recover_options              |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|              myisam_repair_threads               |                        1                         |
-------------------------------------------------------------------------------------------------------
|             myisam_sort_buffer_size              |                     8388608                      |
-------------------------------------------------------------------------------------------------------
|               myisam_stats_method                |                  nulls_unequal                   |
-------------------------------------------------------------------------------------------------------
|          ndb_autoincrement_prefetch_sz           |                        32                        |
-------------------------------------------------------------------------------------------------------
|                  ndb_force_send                  |                        ON                        |
-------------------------------------------------------------------------------------------------------
|               ndb_use_exact_count                |                        ON                        |
-------------------------------------------------------------------------------------------------------
|               ndb_use_transactions               |                        ON                        |
-------------------------------------------------------------------------------------------------------
|               ndb_cache_check_time               |                        0                         |
-------------------------------------------------------------------------------------------------------
|                ndb_connectstring                 |                                                  |
-------------------------------------------------------------------------------------------------------
|                net_buffer_length                 |                      16384                       |
-------------------------------------------------------------------------------------------------------
|                 net_read_timeout                 |                       600                        |
-------------------------------------------------------------------------------------------------------
|                 net_retry_count                  |                        10                        |
-------------------------------------------------------------------------------------------------------
|                net_write_timeout                 |                      72000                       |
-------------------------------------------------------------------------------------------------------
|                       new                        |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                  old_passwords                   |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                 open_files_limit                 |                       1024                       |
-------------------------------------------------------------------------------------------------------
|              optimizer_prune_level               |                        1                         |
-------------------------------------------------------------------------------------------------------
|              optimizer_search_depth              |                        62                        |
-------------------------------------------------------------------------------------------------------
|                     pid_file                     |            /var/run/mysqld/mysqld.pid            |
-------------------------------------------------------------------------------------------------------
|                       port                       |                       3306                       |
-------------------------------------------------------------------------------------------------------
|               preload_buffer_size                |                      32768                       |
-------------------------------------------------------------------------------------------------------
|                    profiling                     |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|              profiling_history_size              |                        15                        |
-------------------------------------------------------------------------------------------------------
|                 protocol_version                 |                        10                        |
-------------------------------------------------------------------------------------------------------
|              query_alloc_block_size              |                       8192                       |
-------------------------------------------------------------------------------------------------------
|                query_cache_limit                 |                     1048576                      |
-------------------------------------------------------------------------------------------------------
|             query_cache_min_res_unit             |                       4096                       |
-------------------------------------------------------------------------------------------------------
|                 query_cache_size                 |                     16777216                     |
-------------------------------------------------------------------------------------------------------
|                 query_cache_type                 |                        ON                        |
-------------------------------------------------------------------------------------------------------
|           query_cache_wlock_invalidate           |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|               query_prealloc_size                |                       8192                       |
-------------------------------------------------------------------------------------------------------
|              range_alloc_block_size              |                       2048                       |
-------------------------------------------------------------------------------------------------------
|                 read_buffer_size                 |                      131072                      |
-------------------------------------------------------------------------------------------------------
|                    read_only                     |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|               read_rnd_buffer_size               |                      262144                      |
-------------------------------------------------------------------------------------------------------
|                 relay_log_purge                  |                        ON                        |
-------------------------------------------------------------------------------------------------------
|              relay_log_space_limit               |                        0                         |
-------------------------------------------------------------------------------------------------------
|                rpl_recovery_rank                 |                        0                         |
-------------------------------------------------------------------------------------------------------
|                   secure_auth                    |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                 secure_file_priv                 |                                                  |
-------------------------------------------------------------------------------------------------------
|                    server_id                     |                        0                         |
-------------------------------------------------------------------------------------------------------
|              skip_external_locking               |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                 skip_networking                  |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                skip_show_database                |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|            slave_compressed_protocol             |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                slave_load_tmpdir                 |                      /tmp/                       |
-------------------------------------------------------------------------------------------------------
|                slave_net_timeout                 |                       3600                       |
-------------------------------------------------------------------------------------------------------
|                slave_skip_errors                 |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|            slave_transaction_retries             |                        10                        |
-------------------------------------------------------------------------------------------------------
|                 slow_launch_time                 |                        2                         |
-------------------------------------------------------------------------------------------------------
|                      socket                      |           /var/run/mysqld/mysqld.sock            |
-------------------------------------------------------------------------------------------------------
|                 sort_buffer_size                 |                     2097144                      |
-------------------------------------------------------------------------------------------------------
|                 sql_big_selects                  |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                     sql_mode                     |                                                  |
-------------------------------------------------------------------------------------------------------
|                    sql_notes                     |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                   sql_warnings                   |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                      ssl_ca                      |                                                  |
-------------------------------------------------------------------------------------------------------
|                    ssl_capath                    |                                                  |
-------------------------------------------------------------------------------------------------------
|                     ssl_cert                     |                                                  |
-------------------------------------------------------------------------------------------------------
|                    ssl_cipher                    |                                                  |
-------------------------------------------------------------------------------------------------------
|                     ssl_key                      |                                                  |
-------------------------------------------------------------------------------------------------------
|                  storage_engine                  |                      MyISAM                      |
-------------------------------------------------------------------------------------------------------
|                   sync_binlog                    |                        0                         |
-------------------------------------------------------------------------------------------------------
|                     sync_frm                     |                        ON                        |
-------------------------------------------------------------------------------------------------------
|                 system_time_zone                 |                       PST                        |
-------------------------------------------------------------------------------------------------------
|                   table_cache                    |                        64                        |
-------------------------------------------------------------------------------------------------------
|             table_lock_wait_timeout              |                        50                        |
-------------------------------------------------------------------------------------------------------
|                    table_type                    |                      MyISAM                      |
-------------------------------------------------------------------------------------------------------
|                thread_cache_size                 |                        8                         |
-------------------------------------------------------------------------------------------------------
|                   thread_stack                   |                      131072                      |
-------------------------------------------------------------------------------------------------------
|                   time_format                    |                     %H:%i:%s                     |
-------------------------------------------------------------------------------------------------------
|                    time_zone                     |                      SYSTEM                      |
-------------------------------------------------------------------------------------------------------
|                  timed_mutexes                   |                       OFF                        |
-------------------------------------------------------------------------------------------------------
|                  tmp_table_size                  |                     33554432                     |
-------------------------------------------------------------------------------------------------------
|                      tmpdir                      |                       /tmp                       |
-------------------------------------------------------------------------------------------------------
|           transaction_alloc_block_size           |                       8192                       |
-------------------------------------------------------------------------------------------------------
|            transaction_prealloc_size             |                       4096                       |
-------------------------------------------------------------------------------------------------------
|                   tx_isolation                   |                 REPEATABLE-READ                  |
-------------------------------------------------------------------------------------------------------
|            updatable_views_with_limit            |                       YES                        |
-------------------------------------------------------------------------------------------------------
|                     version                      |                5.0.51a-3ubuntu5.8                |
-------------------------------------------------------------------------------------------------------
|                 version_comment                  |                     (Ubuntu)                     |
-------------------------------------------------------------------------------------------------------
|             version_compile_machine              |                      x86_64                      |
-------------------------------------------------------------------------------------------------------
|                version_compile_os                |                 debian-linux-gnu                 |
-------------------------------------------------------------------------------------------------------
|                   wait_timeout                   |                      28800                       |
-------------------------------------------------------------------------------------------------------

by EeeeEfff
Fri 03 Feb 2012 06:30
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

I just confirmed that my entire workflow works just fine, so long as the initial data set I am looping through does not exceed 80 records. Is there a paging limit I need to set somewhere??

Thanks!
by EeeeEfff
Thu 02 Feb 2012 14:07
Forum: dotConnect for MySQL
Topic: Lost connection to MySql server during query
Replies: 9
Views: 2971

Lost connection to MySql server during query

Hi,
I've just experienced the same problem posted on http://www.devart.com/forums/viewtopic.php?p=78102. IDE or not, I still get a "Lost connection to MySQL server during query". Full Exception stack is below.

My setup was as follows:
I had a connection open, and I was iterating over ~6000 records (as an IQueryable), taking data from each record and constructing a new OR object (the new OR objects are detached from the context). Each new OR object went into an IList which later would be BulkLoaded, but I never get that far. About 70-80 records into my foreach loop, I encounter the problem below.

My timeout parameters at the server are long. Nothing is shorter than 5 minutes; this occurs a few seconds into my process.

I see that dotConnect for MySql 6.70 is out, but I don't want to upgrade (yet - I am running 6.50.250) unless there is some known issue in there that would address this.

Any help would greatly be appreciated.
Thanks!

Error on reading data from IDataReader.
at Devart.Data.Linq.LinqCommandExecutionException.CanThrowLinqCommandExecutionException(String message, Exception e)
at Devart.Data.Linq.Provider.ObjectReader`1.MoveNext()
at System.Linq.Seq.d__20`1.MoveNext() in C:\dev\wrkspc.......:line 486
at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
at Extract.KPIs() in C:\dev\wrkspc.................:line 162
Lost connection to MySQL server during query
at Devart.Common.aj.a(Exception A_0)
at Devart.Data.MySql.bh.a(Exception A_0)
at Devart.Common.s.e(Byte[] A_0, Int32 A_1, Int32 A_2)
at Devart.Data.MySql.bk.a(Byte[] A_0, Int32 A_1, Int32 A_2)
at Devart.Data.MySql.bk.a()
at Devart.Data.MySql.bk.b(Byte[] A_0)
at Devart.Data.MySql.u.a(Byte[] A_0)
at Devart.Data.MySql.u.a(Byte[] A_0, Boolean A_1)
at Devart.Data.MySql.an.f()
at Devart.Data.MySql.a2.b(Boolean A_0)
at Devart.Data.MySql.MySqlDataReader.a(Boolean A_0)
at Devart.Data.MySql.MySqlDataReader.System.IDisposable.Dispose()
at Devart.Common.l.a(Int32 A_0, Object A_1, Int32 A_2, Object A_3)
at Devart.Common.l.a.a(Int32 A_0, Int32 A_1, Object A_2, l A_3)
at Devart.Common.l.a(Int32 A_0, Int32 A_1, Object A_2)
at Devart.Common.DbConnectionInternal.a(Int32 A_0, Int32 A_1)
at Devart.Common.DbConnectionBase.Close()
at Devart.Data.MySql.MySqlConnection.Close()
by EeeeEfff
Thu 02 Feb 2012 00:18
Forum: MySQL Data Access Components
Topic: Lost connection to MySql server during query
Replies: 6
Views: 7869

I've just experienced this same problem. IDE or not, I still get a "Lost connection to MySQL server during query". Full Exception stack is below.

Error on reading data from IDataReader.
at Devart.Data.Linq.LinqCommandExecutionException.CanThrowLinqCommandExecutionException(String message, Exception e)
at Devart.Data.Linq.Provider.ObjectReader`1.MoveNext()
at System.Linq.Seq.d__20`1.MoveNext() in C:\dev\wrkspc.......:line 486
at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
at Extract.KPIs() in C:\dev\wrkspc.................:line 162
Lost connection to MySQL server during query
at Devart.Common.aj.a(Exception A_0)
at Devart.Data.MySql.bh.a(Exception A_0)
at Devart.Common.s.e(Byte[] A_0, Int32 A_1, Int32 A_2)
at Devart.Data.MySql.bk.a(Byte[] A_0, Int32 A_1, Int32 A_2)
at Devart.Data.MySql.bk.a()
at Devart.Data.MySql.bk.b(Byte[] A_0)
at Devart.Data.MySql.u.a(Byte[] A_0)
at Devart.Data.MySql.u.a(Byte[] A_0, Boolean A_1)
at Devart.Data.MySql.an.f()
at Devart.Data.MySql.a2.b(Boolean A_0)
at Devart.Data.MySql.MySqlDataReader.a(Boolean A_0)
at Devart.Data.MySql.MySqlDataReader.System.IDisposable.Dispose()
at Devart.Common.l.a(Int32 A_0, Object A_1, Int32 A_2, Object A_3)
at Devart.Common.l.a.a(Int32 A_0, Int32 A_1, Object A_2, l A_3)
at Devart.Common.l.a(Int32 A_0, Int32 A_1, Object A_2)
at Devart.Common.DbConnectionInternal.a(Int32 A_0, Int32 A_1)
at Devart.Common.DbConnectionBase.Close()
at Devart.Data.MySql.MySqlConnection.Close()
by EeeeEfff
Fri 28 Oct 2011 17:26
Forum: LinqConnect (LINQ to SQL support)
Topic: no exception on DataContext.Connection.Open() ?
Replies: 5
Views: 1923

Before making any changes, I tried running this morning and did not get the exception. So that's the problematic behavior that I had been observing.

In the debugger, user-unhandled CLR exceptions were already enabled. I turned on the other checkbox too so that all thrown CLR exceptions are triggered. All of a sudden, I started getting the exception. So then I turned off the "all thrown CLR exceptions" checkbox, going back to the original setting, and the exception continued to come up!

Is there something in the context that gets cached in some file somewhere that wasn't getting cleared?

This is really weird.

Thanks,
E.
by EeeeEfff
Thu 27 Oct 2011 21:00
Forum: LinqConnect (LINQ to SQL support)
Topic: no exception on DataContext.Connection.Open() ?
Replies: 5
Views: 1923

Thanks for your response.

- the version of LinqConnect (or dotConnect for MySQL) you are using;
LinqConnect 3.0.10
- what exactly is wrong in the connection string;
Anything: incorrect user, password, host, etc..
- what error message does the MySQL server return when you open the connection object cast to MySQLConnection
Maybe I mis-stated the problem. I want an exception to be thrown. The problem is that I can pass junk to the data context as a connection string, call context.Connection.Open and Close and everything passes - no exception.
When I create a MySqlConnection and pass it a bogus connection string, upon calling Open(), I get the following exception, which is good:
A first chance exception of type 'System.InvalidOperationException' occurred in Devart.Data.MySql.dll
Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.

My connection string in this case is below:
User Id=root;Password=mysql;Host=localhost;Database=blah

If I pass this connection string to the data context constructor, call context.Connection.Open and Close and everything passes - no exception. That's the problem.

I can do my test explicitly using the MySqlConnection object, and that detects invalid logins/schema/host/etc., but I don't understand why connecting with the DataContext is passing the connection.Open, despite being provided a connection string with invalid logins/schema/host/etc..

Thanks.
E.
by EeeeEfff
Wed 26 Oct 2011 20:26
Forum: LinqConnect (LINQ to SQL support)
Topic: no exception on DataContext.Connection.Open() ?
Replies: 5
Views: 1923

no exception on DataContext.Connection.Open() ?

Hi,
I am experiencing a strange problem, but maybe I'm doing something wrong.

Using the following snippet, if I pass an invalid connection string to my data context, I don't get an exception, nor an indication that the DataContext encountered any problems.

Code: Select all

    var ctxt = new MyDataContext(myConnectionString);
    ctxt.Connection.Open();
    ctxt.Connection.Close();
Using the following snippet (explicitly connecting using a MySqlConnection object), if I pass an invalid connection string to my data context, an exception does get thrown.

Code: Select all

    var connection = new MySqlConnection(myConnString);
    connection.Open();
    connection.Close();
So, without explicitly using the MySqlConnection API, how do I test that I have a valid connection to the database before proceeding to use my entity objects?

Any help would be appreciated.

Thanks,
E.
by EeeeEfff
Wed 26 Oct 2011 04:50
Forum: dotConnect for MySQL
Topic: Programatically switch database connection string?
Replies: 4
Views: 2393

Hi - I am having a similar problem, except I need to be able to allow different logins/passwords. I have removed the entire ConnectionString attribute from the lqml file and regenerated the code. The generated DataContext code reflects the change in that the connection string does not exist. But here's the problem: no matter what I provide the data context constructor as the connection string, I still get a successful connection. Is this information cached somewhere?

Any help would be much appreciated.

Thanks,
E.