[GNC] How do I search foi empty description, notes or memo fields

Kalpesh Patel kalpesh.patel at usa.net
Fri Aug 4 13:08:21 EDT 2023


If you need to include white space such as a space, a tab, a carriage
return, a line feed, or a form feed as construing null, it would be:

^\s*$

This is thinking from perspective that you are looking at the description
which shows no visible characters thinking that it is blank else John's
suggestion is gold.

-----Original Message-----
From: John Ralls <jralls at ceridwen.us> 
Sent: Thursday, August 03, 2023 7:01 PM
To: Gilberto Reis Filho <gilberto.reis.filho at gmail.com>
Cc: gnucash-user at gnucash.org
Subject: Re: [GNC] How do I search foi empty description, notes or memo
fields



> On Aug 3, 2023, at 3:35 PM, Gilberto Reis Filho
<gilberto.reis.filho at gmail.com> wrote:
> 
> Hello.
> 
> I have a fairly large database of transactions that I want to search 
> for empty (null) description, notes or memo fields.
> 
> Using the provided search function I always have to type some text to 
> perform a search.
> 
> Is there any way to search for "null" fields in the database using the 
> built in Find Transaction function?
> 
> I am using version 5.3 in Windows and the XML backend.

You can use matches regex and ^$ or doesn't match regex and .+  . In regular
expressions ^ means the beginning of the string and $ means the end, so ^$
is an empty string. Conversely . means any character and + means
one-or-more, so .+ matches anything. Note that * in place of + means
zero-or-more so .* will match any contents or none at all. It has its uses
but this wouldn't be one of them.

Regards,
John Ralls





More information about the gnucash-user mailing list