How to compare 2 files and create a result file with unmatched lines from first file.?

HI,

I have 2 text files. file1 and file2.

file1.txt (There are no duplicates in this file)
1234
3232
4343
3435
6564
6767
1213

file2.txt 
1234,wq,wewe,qwqw
1234,as,dfdf,dfdf
4343,asas,sdds,dsds
6767,asas,fdfd,fdffd

I need to search each number in file1.txt in file2.txt's 1st field (fields are delimited by comma in file2.txt). If the match is not found in file2.txt then i need to put the unmatched numbers from file1.txt to file3.txt

output
file3.txt
3232
3435
6564
1213

can anyone give me a solution.
If possible using awk, since it is faster i believe.

awk -F, 'FNR==NR {f2[$1];next} !($0 in f2)' file2.txt file1.txt
Got the below error
awk: Input line cannot be longer than 3,000 bytes.

I guess the line size inside the 2nd file is more tha 3000 bytes.

Any other solution?

what OS are you on? Do you have nawk? Do you have gawk?

i am using HP-UX. there is no nawk or gawk commands on this.
Can i do it using any other command which takes less time?
currently i am using the below block
but i guess it will take a lot of time. There are more than 10000 lines in a file.

while read line
do
	search_count=`grep -c $line file2.txt`
	echo $grepped
	if [ $grepped -eq 0 ]; then
       echo $line >> unfetch.txt
	fi
done < file1.txt

how about:

cut -d , -f1 file2 | awk 'FNR==NR {f2[$1];next} !($0 in f2)' - file1

Please try this

sort file1.txt > tmp1
cut -d, -f1 file2.txt | sort | uniq > tmp
diff tmp tmp1 | grep '>' | sed -e 's/> //g' > file3.txt
rm -f tmp1 tmp