I have a big file of N-Triples/N-Quads
I want to be left with a collection of only subjects.
On smaller files I could have achieved this using:
awk '{print $1}' | uniq
but awk fails for large files lines. (several MB).
How can I achieve something similar with sed/grep -o/etc'...?
EDIT:
awk fails with:
awk: program limit exceeded: maximum number of fields size=32767
FILENAME="file.nq" FNR=308254 NR=308254