V4RB SQL Select Problem

Cindy alvin at ins.co.nz
Tue Oct 14 18:44:21 CDT 2003


Hi Ruslan,

I thought I had fixed it but seems I was wrong. I cannot get a select query
to compare one field with another field. My Age-3 (now AgeN3) field works
out the age of the student less 3 years. I then want to know all students
who have a ministry year that is less than or equal to that method field
(AgeN3). Both in viSQL and in V4RB I get a 616 error and the select fails. I
can display all with a ministry year less than 3, for example, but that is
not what I want. I want to bring up a select based on the results of two
different fields - only select the records whose ministry year is less than
their age-3.

Any help on this would be appreciated.

Cindy

> on 10/13/03 23:16, Cindy at alvin at ins.co.nz wrote:
> 
>> Hi,
>> 
>> I was wondering if anyone can tell me where I am going wrong.
>> 
>> This select was working on 1.9.7 but now on the latest download (1.9.8) it
>> is crashing my program:
>> 
>> Select Last_PreferredName, Room, Year, Gender, Date_Started_School,
>> Ministry_Year From Students WHERE Age_Years <= 8 AND Ministry_Year >= Age-3
>> 
>> If I take the last bit off (Ministry_Year >= Age-3) then the query works.
>> 
>> Ministry_Year is a Short Field.
>> 
>> Age-3 is a Float field with a method. The method calculates correctly. It's
>> just the comparison that fails.
> 
> Hi Cindy,
> 
> First of all, since you have problems with 1.9.8 switch:
>   -- are you aware about new record locks parameters?
> 
> If no then this can be reason.
> Please read docs about SqlSelect() new parameters.
> 
> 
> If this is not an issue, then you can try do that query from visQL to see if
> it crashes.



More information about the Valentina mailing list