Date: prev next · Thread: first prev next last
2016 Archives by date, by thread · List index


Hoi Dick,

Ik stuur dit ook direct, zodat je de plaatjes ook ontvangt.

Als je een query bewerkt in SQL-weergave, zou hij dat niet moeten doen. In het hoofd venster klik je de query aan en druk op de rechter muisknop.

Plaatje 1

Je krijgt dan het sql script te zien waar je de where clausule kunt aanpassen. Na wat googlen kon ik dit vinden:

WHERE Tabel1.naam like '%' || Tabel1.deel || '%'

De plusjes die ik eerder stuurde deden het niet. De | noemen ze een pipe en zit vlak boven de enter-toets bij mij.

"I suggest you use two pipe characters ( || ) to tell the database engine that you want to concatenate ( combine data together )."

Ik heb het net geprobeerd in een database die ik effe snel had gemaakt en die werkte wel.

Plaatje 2

Ik hoop dat het zo wel lukt.

Groeten!


Op 10-08-16 om 07:40 schreef Dick Stomp:
Wily,
Jouw oplossing wordt vertaald naar:
'like  ''%'' + "Query_4201"."Omschrijving" + ''%'''
Dick

Op 9 augustus 2016 22:26 schreef Rob Westein <rwestein@planet.nl>:

Ziet er goed uit!


Op 09-08-16 om 19:24 schreef Wily Bijk:

Dit is volgens mij een alternatief, maar ik kan het niet zo goed testen.
SELECT "Query_4201"."Datum", "Query_4201"."IBAN",
"Query_4201"."Benaming",
"Query_4201"."Bedrag", "Query_4201"."Omschrijving", "Query_4201"."kost",
"TekstKostp"."ID", "TekstKostp"."zoektekst", "TekstKostp"."kostp",
"TekstKostp"."reden"
FROM { "TekstKostp"
RIGHT OUTER JOIN "Query_4201"
ON "TekstKostp"."zoektekst" = "Query_4201"."Omschrijving" }
WHERE "TekstKostp"."zoektekst"  like  '%' + "Query_4201"."Omschrijving" +
'%'
ORDER BY "Query_4201"."kost"
ASC


In Base is de % een joker, waar dat in access * is.  Deze plak je voor en
achter het veld omschrijving, zodat je een 'pattern' krijgt waar zoektekst
aan moet voldoen.



Op 09-08-16 om 15:27 schreef Rob Westein:

Hoe heb je dat in ms-access opgelost dan?

Volgens mij moet het wel kunnen...

/Rob


Op 09-08-16 om 15:19 schreef Dick Stomp:

Rob, bedankt!
Ik gebruik http://www.w3schools.com/sql/
Daar staat dat de LIKE gevolgd moet worden door *pattern* en niet door
een
*veldnaam*.
Het kan dus gewoon niet.
Waarschijnlijk moet ik -afwijkend van het Procedureel Ontwerp-
achterstevoren werken. Dus de zoekwoordjes worden leading, stuk voor
stuk
en alle records van de Betalingen worden keer op keer onderzocht op
Omschrijving of het woordje daar in zit. Wel erg omslachtig...
Dat ga ik uitzoeken.
Dick

2016-08-09 14:52 GMT+02:00 Rob Westein <rwestein@planet.nl>:

ohh hier een link naar documentatie voor HSQL:
http://hsqldb.org/web/hsqlDocsFrame.html

/Rob
Op 09-08-16 om 14:48 schreef Rob Westein:


Op 09-08-16 om 09:59 schreef Dick Stomp:
Dag Rob,
Hoi Dick,
Het ziet er als volgt uit:
SELECT "Query_4201"."Datum", "Query_4201"."IBAN",
"Query_4201"."Benaming",
"Query_4201"."Bedrag", "Query_4201"."Omschrijving",
"Query_4201"."kost",
"TekstKostp"."ID", "TekstKostp"."zoektekst", "TekstKostp"."kostp",
"TekstKostp"."reden"
FROM { "TekstKostp"
RIGHT OUTER JOIN "Query_4201"
ON "TekstKostp"."zoektekst" = "Query_4201"."Omschrijving" }
WHERE "TekstKostp"."zoektekst" = 'like "Query_4201"."Omschrijving"'
ORDER BY "Query_4201"."kost"
ASC
De fout zit in WHERE: de "like" wordt niet herkend en het statement
krijgt
enkel-quote's om zich heen.

Op het eerste gezicht denk ik dat de WHERE statement niet correct
is...
Syntax is: WHERE <veldnaam> LIKE <conditie>

/Rob

Groet,
Dick





--
Unsubscribe instructions: E-mail to users+unsubscribe@nl.libreoffi
ce.org
Posting guidelines + more: http://wiki.documentfoundation
.org/Netiquette
List archive: http://listarchives.libreoffice.org/nl/users/
All messages sent to this list will be publicly archived and cannot be
deleted






--
Unsubscribe instructions: E-mail to users+unsubscribe@nl.libreoffice.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/nl/users/
All messages sent to this list will be publicly archived and cannot be
deleted





--
Unsubscribe instructions: E-mail to users+unsubscribe@nl.libreoffice.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/nl/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.