Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can't filter NULL values from cursor returned by SQL Ser
Message
From
07/02/2007 04:28:43
 
 
To
07/02/2007 04:21:34
Aye Mya Thida Kyaw
Ingenuity Microsystems Sdn Bhd.
Kuala Lumpur, Malaysia
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Database:
MS SQL Server
Miscellaneous
Thread ID:
01192681
Message ID:
01193122
Views:
14
>I send the SPT to SQL Server and receive the recordset with a VFP Cursor. In the processing with that cursor, when I want to filter a field whether it's empty or null by using these functions like EMPTY() or ISNULL(), I can't get a correct answer eventhough the field is having NULL value. For Example:
>
>IF ISNULL(temployee.remarks) or EMPTY(temployee.remarks)
> this.value=""
>ELSE
> this.value=temployee.remarks
>ENDIF
>
>The condition is always false eventhough the value is having NULL.
>What else function should i use or am i wrong filtering?
>Appreciating all your suggestions.
>Thanks.
>
>Mya

I donæt use SQL server myself, but my guess is that your cursor simply has NULL as text. Check for temployee.remarks#'NULL'.
Previous
Reply
Map
View

Click here to load this message in the networking platform