Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ SQL » Setting SQLite language?!
Setting SQLite language?! [message #12853] Wed, 21 November 2007 18:18 Go to next message
alex100 is currently offline  alex100
Messages: 118
Registered: November 2007
Experienced Member
Hi all,

How to format, during creating or not, the language of the SQLite database?

In my app I set the language using OS language like this:

GUI_APP_MAIN
{
...
::SetLanguage( ::GetSystemLNG() );

theApp.Run();
}

If I insert PT chars in a database field thos chars are not recorded:



if(!SQL.Execute(Format("update Groups set NAME='%s' where ID > 1","Joćo")))
PromptOK("Erro a executar o update!");


When I read from the table I just see the
"Jo" and nothing else:


SQL.Execute("select * from groups");
while(SQL.Fetch())
Exclamation(Format("%d - %s",SQL[0],SQL[1]));

Thank you very much


Alex
Re: Setting SQLite language?! [message #12860 is a reply to message #12853] Thu, 22 November 2007 12:53 Go to previous message
alex100 is currently offline  alex100
Messages: 118
Registered: November 2007
Experienced Member
Done!

What happened was that if I insert portuguese text comming from an edit boxe the characters were written ok but if I insert static text (from the theIDE editor) in the database the text get wrong charset. So do not forget to set the character set of the theIDE editor!

Setup|Environment|Editor|Default charset


Alex
Previous Topic: [SQLite] db.Open() crashes app
Next Topic: Example code for CtrLib/Sqlite needed
Goto Forum:
  


Current Time: Sat May 18 04:18:39 CEST 2024

Total time taken to generate the page: 0.04194 seconds