[GNC] Unable to enter data in "Description" field of a Transaction

G R Hewitt hewittgr at gmail.com
Tue Aug 1 16:16:32 EDT 2023


I didn't understand the code, I just copied and pasted it.
I did wonder about there being a random character as I copied and pasted it
from the online account.
I blitzed the description text in all occurrences and typed it in to make
sure it was clean.
Very strange that it is just (so far) 'Tes' or 'tes', especially if you use
back-space to delete, as soon as the last 't' of 'Test' is deleted it locks
up the program.
I await your findings with interest.

On Tue, 1 Aug 2023 at 19:46, john <jralls at ceridwen.us> wrote:

> Tesco is left out of the search by the `[^c]` term in the regular
> expression: It allows any character except c after "tes".
>
> The bit about Test is interesting. I was expecting the problem to be
> something other than a normal character; the implication is that it has
> something to do with the last character in the string. I'll experiment with
> that a bit.
>
> Regards,
> John Ralls
>
> On Jul 31, 2023, at 23:16, G R Hewitt <hewittgr at gmail.com> wrote:
>
> With regards to my previous answer, I decided to delete the word 'Test'
> from 'Car Annual Test' and replaced it with 'NCT'. I could, in the first
> instance, only backspace delete the 's' of 'Test' as it froze.
> Then I entered the word 'Tesco' in the'Bank' register description and it
> went in just fine.
> I then replaced 'NCT' with 'Test' and the problem returned.
> I have left it as 'NCT'.
>
> ------------------------------
>
> Okay John, done that.
>
> Search = [[:<:]]tes[^c]
>
> Returns two entries and the description for both is 'Car Annual Test' -
> which gives the 'Tes' in question.
> Oddly there are no 'Tesco' transactions - ought there to be, I should have
> thought so?
> The entries are:
> Bank > Prepayments
> Prepayments > Car
>
> Search = [[:<:]]tes[^a-z] Returns nothing.
>
> On Mon, 31 Jul 2023 at 18:28, john <jralls at ceridwen.us> wrote:
>
>> We need to move this back to the list, your results are of general
>> interest and I don't think that they reveal anything private.
>>
>> The matcher only tries to match on the beginning of words, so whatever is
>> causing the problem starts with `tes` and `ates` won't match it.
>>
>> Let's try to find it: Open the find dialog (Edit>Find or cmd-F) in the
>> register. Select "matches regex" from the list button after "Description"
>> and enter "[[:<:]]tes[^c]" (no quotes) and click Find. That will present a
>> list of transactions with descriptions having words starting with tes that
>> aren't tesco. If it's too many to look through try "[[:<:]]tes[^a-z]"; that
>> will show only entries where tes is followed by something that isn't a
>> letter.
>>
>> Regards,
>> John Ralls
>>
>>
>>
>


More information about the gnucash-user mailing list