Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

if-Anweisung

Hallo,

ich habe derzeit folgende If-Formel als Filter in einer Auswertung:

=if(left(Lagerplatz,5)='KX/SL','XX','OO')

Nun möchte ich jedoch die Abfrage erweitern, dass alle Lagerplätze mit 'SL' an der 4. und 5. Stelle selektiert werden können.

Ein Hinweis:

Der Lagerplatz insgesamt hat 11 Stellen. Über die Right-Formel hätte ich somit das gleiche Problem. Wie kann ich eine Zeichenfolge in der Mitte filtern?

Vielen Dank für eine Rückmeldung im Voraus!

Grüße

Anita

6 Replies
Anil_Babu_Samineni

May be this? Read more Mid - script and chart function ‒ QlikView

=if(left(Mid(Lagerplatz,10,5),5)='KX/SL','XX','OO')

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
zhadrakas
Specialist II
Specialist II

Hallo Anita,

schau dir mal die mid() Funktion an

Mid ‒ QlikView

Anonymous
Not applicable
Author

Hallo,

vielen Dank für eure Rückmeldungen. Habe es versucht umzusetzen und habe wohl noch einen Fehler in der Formel:

=If(mid(Lagerplatz.StoreLocation,4,5)='SL' or mid (Lagerplatz.Storelocation,5,6)='SL'or mid (Lagerplatz.Storelocation,9,10)='SL', 'Servicelager', 'Operatives Lager')

Kann mir hierzu noch jemand einen Tip geben?

Anil_Babu_Samineni

Sieht gut aus, Was ist das genaue Problem, vor dem Sie stehen?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
swuehl
MVP
MVP

Das dritte Argument sollte die Anzahl der Zeichen angeben, nicht die Endposition:

=If(mid(Lagerplatz.StoreLocation,4,2)='SL' or mid (Lagerplatz.Storelocation,5,2)='SL'or mid (Lagerplatz.Storelocation,9,2)='SL', 'Servicelager', 'Operatives Lager')

Anonymous
Not applicable
Author

super, das war der entscheidende Hinweis. Danke!

Grüße

Anita Kienzler

Von: Stefan Wühl

Gesendet: Freitag, 12. Januar 2018 15:16

An: Kienzler, Anita

Betreff: Re: - if-Anweisung