My LC application is in IDE mode working fine with the MySQL connection using localhost on XP with LC4.6.4.
I am using a number of datagrids and the data from the database is working fine.
I use 2 buttons to get data from 1 table of the database into a datagrid. Records with status 'actual' and records with status 'archive' are seperatly selected.
When I click a line in the datagrid, all related data from that line are distributed to separate fields on the same card as the datagrid, from different tables in the database. Sofar everything goes nice and wanted.
But when I create a standalone application, its all different and not working at all.
I checked the connection to the database in the standalone and that's working.
But there are no records coming into the datagrid. The datagrid does not seem to work at all, because also when I enlarge the screen, it should grow vertical up/down and horizontal to the right/left, but the enlargment only takes the surrounding rectangle, but leaves the scrollbars and the actual datagrid where they are.
I checked the 'Data Grid Templates' in the standalonedirectory, and its there, so nothing seems to be missing.
When I click on a line in the datagrid, and thereby select an old previous record, I get a message in one of the fields, saying: " revdberr, You have an error in your SQL syntax, check the manual that correspondents to your MySQL server version for the right syntax to use near " at line 1 ". This seems to be logical, because there is no "new" data in the datagrid. but still I don't understand it.
I also tried to work with a 'Data Grid Template Dub', which is recommended in one of the lessons, but it has no effect.
In creating the standalone I tried both inclusions.
Has somebody some idea whats wrong here?
Please help,
thanks
Rob van der Sloot
MySQL server syntax problem in standalone?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Livecode Opensource Backer
- Posts: 79
- Joined: Sat Apr 17, 2010 9:21 am
Re: MySQL server syntax problem in standalone?
You have to "qualify" your problem.
Datagrid ? MySQL ? Other ?
So first, work on MySQL, the easier part :
-open the connection
-read data from the DB
-display the data by using a simple answer TheData or put theData into "myField"
Idea to open the connection : replace "localhost" by "127.0.0.1"
If everything OK, then you'll have to look at your datagrid.
Regarding : "I click on a line in the datagrid, and thereby select an old previous record, I get a message in one of the fields, saying: " revdberr, You have an error in your SQL syntax, check the manual that correspondents to your MySQL server version for the right syntax to use near " at line 1 ".
You need to display the SQL query, to see what's wrong.
Datagrid ? MySQL ? Other ?
So first, work on MySQL, the easier part :
-open the connection
-read data from the DB
-display the data by using a simple answer TheData or put theData into "myField"
Idea to open the connection : replace "localhost" by "127.0.0.1"
If everything OK, then you'll have to look at your datagrid.
Regarding : "I click on a line in the datagrid, and thereby select an old previous record, I get a message in one of the fields, saying: " revdberr, You have an error in your SQL syntax, check the manual that correspondents to your MySQL server version for the right syntax to use near " at line 1 ".
You need to display the SQL query, to see what's wrong.
Re: MySQL server syntax problem in standalone?
Got a question about the datagrid problem you mention. Do you use a splashstack for your app? If so, you might want to read here. http://lessons.runrev.com/s/lessons/m/d ... Data-Grid-
Scroll down to the splashstack section and see if you can end up with a working datagrid.
Scroll down to the splashstack section and see if you can end up with a working datagrid.
-
- Livecode Opensource Backer
- Posts: 79
- Joined: Sat Apr 17, 2010 9:21 am
Re: MySQL server syntax problem in standalone?
Datagrid ? MySQL ? Other ?
So first, work on MySQL, the easier part :
-open the connection
-read data from the DB
-display the data by using a simple answer TheData or put theData into "myField"
I checked all the possibillities, the SQL connection is ok. The problem seems to be the datagrid. So I removed the datagrid and created a new one.
That did not solve the problem. Next I made a new test stack and only put the datagrid plus two buttons to get the data in. Then made a standalone of this test stack and there it worked fine. So the problem is somewhere in the code. So I think the best is to rebuilt the whole stack again and test everytime in standalone mode.
I already tried the splashstack setup, but that was no option.
Sofar thanks for the help.
So first, work on MySQL, the easier part :
-open the connection
-read data from the DB
-display the data by using a simple answer TheData or put theData into "myField"
I checked all the possibillities, the SQL connection is ok. The problem seems to be the datagrid. So I removed the datagrid and created a new one.
That did not solve the problem. Next I made a new test stack and only put the datagrid plus two buttons to get the data in. Then made a standalone of this test stack and there it worked fine. So the problem is somewhere in the code. So I think the best is to rebuilt the whole stack again and test everytime in standalone mode.
I already tried the splashstack setup, but that was no option.
Sofar thanks for the help.