Hello,
I have a problem with reading VARCHAR data out of a MySql database over ODBC. The datatype of the field is VARCHAR(255). When I read the data and put it in a grid coloumn (data type: long string) everything is fine. But when I try to put the same data into a combobox (data type: long string) nothing is displayed in the combobox.
Does anybody has an idea if this is a bug?
Kind regards,
Frank
TD-16046: Problem reading VARCHAR out of MySql-Database
Re: Problem reading VARCHAR out of MySql-Database
Yes, a bug. Combobox can be set for Long String, but it seems v6 is ignoring that and assuming String. Workaround for the moment is to first fetch into a var. of type Long String, then assign that to the combobox, like:
I've added TD-16046 for this defect. I'll attach the SQLBase ISLAND test case for this, FYI.
Code: Select all
If NOT SqlPrepareAndExecute( hSql,
'SELECT TXT INTO :lsForComboBox FROM TEST_COMBO where id = :df1' )
Return FALSE
If SqlFetchNext( hSql, nInd )
Call SalListAdd( cmbLongString, lsForComboBox )
Call SalListSetSelect( cmbLongString, 0 ), '', 0 )
You do not have the required permissions to view the files attached to this post.
Re: Problem reading VARCHAR out of MySql-Database
Frank -- development had a chance to look at this issue and cannot reproduce a problem. I should have asked you for a test case, but I had put one together and between dev. and I we tested with MS SS/SQLBase (me) MySQL/Oracle (developer) with no problems.
I'll attach the TD v6 SP5 defect's test case; you need to set login params. on form's SAM_Create to test.
TD-16046 is currently 'resolved' as "Cannot reproduce" pending you providing us a test case + details that do fail for you. The test case attached does not fail for us.
I'll attach the TD v6 SP5 defect's test case; you need to set login params. on form's SAM_Create to test.
TD-16046 is currently 'resolved' as "Cannot reproduce" pending you providing us a test case + details that do fail for you. The test case attached does not fail for us.
You do not have the required permissions to view the files attached to this post.
Re: Problem reading VARCHAR out of MySql-Database
Hi Jeff,
thank you for your reply! I will create a test database on my webserver and send you a small program showing you the problem! But please give me a few days as I am very buisy in the moment!
As far as I can see the difference between your test case and the way I try to fill the combo box is that I would like to use the function "SalListPopulate" for that. And this is not working with combo boxes.
Regards,
Frank
thank you for your reply! I will create a test database on my webserver and send you a small program showing you the problem! But please give me a few days as I am very buisy in the moment!
As far as I can see the difference between your test case and the way I try to fill the combo box is that I would like to use the function "SalListPopulate" for that. And this is not working with combo boxes.
Regards,
Frank
Re: Problem reading VARCHAR out of MySql-Database
I mod'd the test and this line works OK to populate the combobox:
Call SalListPopulate( cmbLongString, hSql, 'SELECT TXT FROM TEST_COMBO where id = :df1' )
Check to make sure your combo is Long String type.
Call SalListPopulate( cmbLongString, hSql, 'SELECT TXT FROM TEST_COMBO where id = :df1' )
Check to make sure your combo is Long String type.
Who is online
Users browsing this forum: [Ccbot] and 0 guests