I've recently started at a position and and in the process of cleaning out a mess of uneeded records (1000's). However I have been a Network Tech for a while and am only recently back into programming. I have created the queuery in Crystal (v7 7) and need to create the exact same one in Pervasive 7 so I can delete the records. Any guru's out there able to give me a conversion?
basically the report looks up a field to see what the date is after the word ENDING(I had to cut of the beginning of the field as the date is there also)
--------------
local stringvar ENDING;
local stringvar STARTSTRING;
local numbervar STARTPOINT;
local numbervar LEN;
LEN := Length ({Rules Text.RULE TEXT}); //size of field
STARTPOINT := InStr ({Rules Text.RULE TEXT},"ENDING") -1; //locate startpoint of word ENDING
STARTSTRING := Right ({Rules Text.RULE TEXT}, LEN-StartPoint); //truncate all data in field before the word ENDING
//check if any of the rules in truncated field contain the year 2000-2004
if InStr (STARTSTRING,"2000" ) > 0 or
InStr (STARTSTRING,"2001" ) > 0 or
InStr (STARTSTRING,"2002" ) > 0 or
InStr (STARTSTRING,"2003" ) > 0 or
InStr (STARTSTRING,"2004" ) > 0
then STARTSTRING
else ""; //leave field blank if conditions not met
I'm researching to do it as you read this but I appreciate any help you can give me.
thanks in advance
basically the report looks up a field to see what the date is after the word ENDING(I had to cut of the beginning of the field as the date is there also)
--------------
local stringvar ENDING;
local stringvar STARTSTRING;
local numbervar STARTPOINT;
local numbervar LEN;
LEN := Length ({Rules Text.RULE TEXT}); //size of field
STARTPOINT := InStr ({Rules Text.RULE TEXT},"ENDING") -1; //locate startpoint of word ENDING
STARTSTRING := Right ({Rules Text.RULE TEXT}, LEN-StartPoint); //truncate all data in field before the word ENDING
//check if any of the rules in truncated field contain the year 2000-2004
if InStr (STARTSTRING,"2000" ) > 0 or
InStr (STARTSTRING,"2001" ) > 0 or
InStr (STARTSTRING,"2002" ) > 0 or
InStr (STARTSTRING,"2003" ) > 0 or
InStr (STARTSTRING,"2004" ) > 0
then STARTSTRING
else ""; //leave field blank if conditions not met
I'm researching to do it as you read this but I appreciate any help you can give me.
thanks in advance