an SQL problem

jimmy jimmy at wagesdesign.com
Fri Mar 21 12:20:42 CST 2003


Hi,

I'm running into a problem...  I'm running Valentina in Director 8.5 for the
PC.  I wrote this SQL statement in the script and it worked perfectly:

set gCursor = new(xtra "VCursor", GetRef(gDB), "Select * FROM Images,
Expertise WHERE Images.ImgCode = Expertise.ImgCode AND
Expertise.Category='Environmental' AND Images.Client='FERNBANK - PD' ORDER
BY Expertise.Order")

Then I had to change it to this:

set gCursor = new(xtra "VCursor", GetRef(gDB), "Select * FROM Images,
Expertise WHERE Images.ImgCode = Expertise.ImgCode AND
Expertise.Category='Environmental' AND (Images.Client='FERNBANK - PD' OR
Expertise.altClient='FERNBANK - PD') ORDER BY Expertise.Order")

(notice the addition of "OR Expertise.altClient='FERNBANK - PD')").  Well,
now it doesn't give me any results at all!  I tried making the same query in
an ASP page to see if it was the SQL query that was written wrong... but in
the ASP page, it gave me the right results.  So I'm not sure what's going
wrong here.

I'm pretty sure the VDB file is correct.  But if you want to look at it I
can send it to you too.

Thanks in advance for any help,

~jimmy.




More information about the Valentina mailing list