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 » Community » Newbie corner » SQL query generator
Re: SQL query generator [message #32988 is a reply to message #32976] Mon, 27 June 2011 21:49 Go to previous messageGo to previous message
BioBytes is currently offline  BioBytes
Messages: 307
Registered: October 2008
Location: France
Senior Member
Hi Jibe,

Happy that I could bring some help. Switch/case seems to be heavy but I think the application is not really slowed going this way.

Meanwhile, I am trying to test that following code:

SqlId FIELD(~fieldsDL);
SqlBool where("Where"+AsString(~opeDL)+AsString(~valueEdit),pr);

SQL *Select(ALL).From(TBLALIMENTS).Where(where);

while(SQL.Fetch())PromptOK(AsString(SQL[0])+" "+AsString(SQL[1]));


The problem is to know what to pass in pr. U++ help tells that pr should be an integer but all my trials fail except when passing pr = 0. In that case, all the records from the table are obtained ignoring the Where condition.

Another way is to use SqlVal but the problem is to get a SqlBool expression from a SqlVal.

I will inform you if I can solve this issue.

Cheers

Biobytes
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Converting HTML to "normal" text
Next Topic: Foreign Languages - For FileSel, PromptOK, and other
Goto Forum:
  


Current Time: Sun May 12 22:29:58 CEST 2024

Total time taken to generate the page: 0.01252 seconds