79384714

Date: 2025-01-24 14:48:12
Score: 5
Natty:
Report link

Thank you, @MT0 and @jdweng, for your valuable insights regarding the trailing semicolon (;). Removing the semicolon resolved the initial ORA-00933: SQL command not properly ended issue. However, I am now encountering two new problems:

When trying to bind parameters, I get the error: ORA-01008: not all variables bound. If I hard-code the parameter values instead of using bind variables, the query runs without errors, the grid and column headers appear in Uyumsoft, but no data is displayed.

    SELECT 
    ENTITY_ID, 
    ENTITY_CODE AS "CARI KOD", 
    ENTITY_NAME AS "CARI AD", 
    IS_EMAIL AS "MAIL GONDERIM", 
    MAIL_ATTACHMENT_INFO AS "MAIL EKLENECEK DOSYA TIPI", 
    E_INVOICE_PROFILE AS "FATURA SENARYO", 
    EINVOICE_START_DATE AS "MUKELLEF TARIHI", 
    IS_EINVOICE_ENTITY AS "E FATURA MUKELLEFI MI", 
    E_INVOICE_DEL_TYPE AS "EFATURA POSTA KUTUSU", 
    EMAIL AS "EFATURA GONDERIM MAILI"
FROM FIND_ENTITY
WHERE 
    (ENTITY_CODE LIKE '%123%')
    AND (IS_EMAIL = 1)
    AND (EINVOICE_START_DATE >= TO_DATE('2025-01-01', 'YYYY-MM-DD'))
    AND (E_INVOICE_DEL_TYPE = '2')

enter image description here

When attempting to use bind variables, the query looks like this:

SELECT 
    ENTITY_ID, 
    ENTITY_CODE AS "CARI KOD", 
    ENTITY_NAME AS "CARI AD", 
    IS_EMAIL AS "MAIL GONDERIM", 
    MAIL_ATTACHMENT_INFO AS "MAIL EKLENECEK DOSYA TIPI", 
    E_INVOICE_PROFILE AS "FATURA SENARYO", 
    EINVOICE_START_DATE AS "MUKELLEF TARIHI", 
    IS_EINVOICE_ENTITY AS "E FATURA MUKELLEFI MI", 
    E_INVOICE_DEL_TYPE AS "EFATURA POSTA KUTUSU", 
    EMAIL AS "EFATURA GONDERIM MAILI"
FROM FIND_ENTITY
WHERE 
    (:EntityCode IS NULL OR ENTITY_CODE LIKE '%' || :EntityCode || '%')
    AND (:IsEmail IS NULL OR IS_EMAIL = :IsEmail)
    AND (:StartDate IS NULL OR EINVOICE_START_DATE >= TO_DATE(:StartDate, 'YYYY-MM-DD'))
    AND (:InvoiceDeliveryType IS NULL OR E_INVOICE_DEL_TYPE = :InvoiceDeliveryType)

Is this issue related to how Uyumsoft is handling the bind variables, or is there something missing in the query syntax/configuration? Any advice would be greatly appreciated.

Thank you again for your help!

Reasons:
  • Blacklisted phrase (0.5): Thank you
  • Blacklisted phrase (1): appreciated
  • RegEx Blacklisted phrase (1): I get the error
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • User mentioned (1): @MT0
  • User mentioned (0): @jdweng
  • Self-answer (0.5):
  • Looks like a comment (1):
  • Low reputation (1):
Posted by: Gökhan