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 » Issue with sql.execute(const String&)
Issue with sql.execute(const String&) [message #28410] Tue, 31 August 2010 22:20 Go to previous message
BioBytes is currently offline  BioBytes
Messages: 307
Registered: October 2008
Location: France
Senior Member
Hi all,

I have a question regarding the command sql.Execute. This is an example from my source code. the query works perfectly if the query is passed as below:

if(sql.Execute("select * from codetechnic where(codefamille='cat' and product='hemoglobin')")PromptOK("query is executed");

In case the query is built using parameters obtained from droplists controls as follows:

String query;

query<<"select * from codetechnic where(codefamille=";
query<<"'";
query<<mydroplist1.GetData().ToString();
query<<"'";
query<<" and product=";
query<<"'";
query<<mydroplist2.GetData().ToString();
query<<"'";
query<<")";


The expression if(sql.execute(query))returns false (????) and true as above.

Is anybody could explain to me how to pass runtime query ?

thank you for your help

regards
Biobytes
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: SQlite3: my problem or bug?
Next Topic: Compiling error for mysql
Goto Forum:
  


Current Time: Mon Apr 29 11:09:35 CEST 2024

Total time taken to generate the page: 0.03204 seconds