Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8346867
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T07:09:41+00:00 2026-06-09T07:09:41+00:00

I am using ado.net and MySQL db. When I insert cyrillic values into db,

  • 0

I am using ado.net and MySQL db. When I insert cyrillic values into db, they are inserted as ‘?’ symbols. I have tried various encodings in db, this didn`t help. I tried utf-8, utf-16, cp-1251 and many others.
So when I execute this code

        MySql.Data.MySqlClient.MySqlConnection con = new MySql.Data.MySqlClient.MySqlConnection("server=localhost;User Id=root;database=voteme");
        MySql.Data.MySqlClient.MySqlCommand cmd = new MySql.Data.MySqlClient.MySqlCommand("INSERT INTO districts(DistrictName) VALUES('іавп')",con);
        con.Open();
        cmd.ExecuteNonQuery();
        con.Close();

I receive ‘????’ stored in my db. How do I solve this problem?
Thanks.

Edit: I tried to use both varchar and text field types in database: result was still the same.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T07:09:43+00:00Added an answer on June 9, 2026 at 7:09 am
    1. Be sure to use UTF8 as database collation.

    2. Try this immediately after opening connection:

      con.ConnectionString = “database=DATABASE;server=localhost;user id=USERNAME;pwd=PASSWORD;CharSet=utf8”; after creating connection.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a C# .NET 3.5 application using the ADO.NET Driver for MySQL (Connector/NET).
I have problem while connecting to mysql database using ADO.NET Driver for MySQL (Connector/NET)
I am trying to develop an application using ADO.NET. I have two tables in
I'm running into a strange corner-case while querying an iSeries server using ADO.NET and
I am inserting values in to Database from a Webform using ADO.NET, C#. DB
Can I connect to a Ubuntu server, that is running MySQL using ADO.NET or
I have a C# application, using ADO.Net to connect to MSSQL I need to
long-time listener, first-time caller! I’m trying to connect to MySQL using the ADO.NET Entity
I am using an ADO .Net Entity Model for querying a MySQL database. I
I am trying to generate my ADO.NET entity model from my MySQL database using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.