× Discuss on Template programming, jBASE programming, Enquiries, No-File enquiry, Enquiry routines, Version, Version routines, Menus, Abbriviations, Creating local reference fields, Fast path enquiries, Creating charts and graphs, Generating Reports, Deal slips, Straight through processing, Multi Company and Multi Book setup, Tabbed screens, Composite Screens, T24 API, etc...

SELECT issue in TAFJ with multiple conditions

  • baskarjay
  • baskarjay's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 37
  • Karma: -1
  • Thank you received: 0

baskarjay created the topic: SELECT issue in TAFJ with multiple conditions

Hi All


This select works in TAFC but not works in TAFJ..

SELECT FBNK.COLLATERAL.TYPE WITH (@ID GE 100 AND @ID LE 399) OR (@ID GE 700 AND @ID LE 849) OR (@ID
GE 900 AND @ID LE 999)


But if we used one condition in select works in TAFJ itself....

SELECT FBNK.COLLATERAL.TYPE WITH (@ID GE 100 AND @ID LE 399)


when we using multiple conditions, its not working... If anyone had solution for this plz let me know
#21633

Please Log in or Create an account to join the conversation.

  • baskarjay
  • baskarjay's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 37
  • Karma: -1
  • Thank you received: 0

baskarjay replied the topic: SELECT issue in TAFJ with multiple conditions

when we using same field in multiple conditions then select not works
#21634

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 555
  • Karma: 10
  • Thank you received: 80

VK replied the topic: SELECT issue in TAFJ with multiple conditions

Hi
Absolutely valid syntax, works in TAFC....
Maybe you try additional parentheses like:
SELECT FBNK.COLLATERAL.TYPE WITH ((@ID GE 100 AND @ID LE 399) OR (@ID GE 700 AND @ID LE 849) OR (@ID GE 900 AND @ID LE 999))

Cheers
VK
#21635
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

  • baskarjay
  • baskarjay's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 37
  • Karma: -1
  • Thank you received: 0

baskarjay replied the topic: SELECT issue in TAFJ with multiple conditions

Hi VK

Thanks for your inputs :)

we tried that too but not worked :(
#21636

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 555
  • Karma: 10
  • Thank you received: 80

VK replied the topic: SELECT issue in TAFJ with multiple conditions

Hi
you definitely have to address a bug report to Temenos.

In the meantime, you can produce a workaround - select 3 times (one criterion on each select) and then concatenate 3 resulting lists...

Cheers
VK
#21637

Please Log in or Create an account to join the conversation.

  • Posts: 274
  • Karma: -2
  • Thank you received: 20

Valleyman1 replied the topic: SELECT issue in TAFJ with multiple conditions

This is the TAFJ format:

SELECT * FROM FBNK_COLLATERAL_TYPE WHERE RECID >= 100 AND RECID <= 399
#21646
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 555
  • Karma: 10
  • Thank you received: 80

VK replied the topic: SELECT issue in TAFJ with multiple conditions

Hi

"GE" and ">=" are the same thing. Also, "LE" and "<=" are the same. So your SELECT is the same as one that worked.
What about "OR"? The topic starter claimed that OR didn't work.

Cheers
VK
#21648
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

  • Posts: 274
  • Karma: -2
  • Thank you received: 20

Valleyman1 replied the topic: SELECT issue in TAFJ with multiple conditions

"GE", "LE" etc not defined in SQL syntax\

"OR" is fine
SELECT * FROM FBNK_COLLATERAL_TYPE WHERE RECID = 100 OR RECID = 399
#21650
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 555
  • Karma: 10
  • Thank you received: 80

VK replied the topic: SELECT issue in TAFJ with multiple conditions

Hi

Your example contains one OR only and not (... AND ..) OR (.. AND ..)

Again, quoting the topic starter - the following SELECT (containing both GE and LE) is claimed to be OK:

SELECT FBNK.COLLATERAL.TYPE WITH (@ID GE 100 AND @ID LE 399)


I don't have TAFJ (and hope I never will :) - maybe you can retest all examples from the initial post under TAFJ?

Cheers
VK
#21652
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

  • Posts: 274
  • Karma: -2
  • Thank you received: 20

Valleyman1 replied the topic: SELECT issue in TAFJ with multiple conditions

The select syntax will work on TAFC, not on TAFJ.

The table names on TAFC is "FBNK.COLLATERAL.TYPE" and on TAFJ is "FBNK_COLLATERAL_TYPE". if one uses SQL the "." needs to be replaced by "_".

If one is using DBTools JQL option can give you something similar to TAFC.
#21654
The following user(s) said Thank You: baskarjay

Please Log in or Create an account to join the conversation.

Time to create page: 0.266 seconds