Subject | SQL Query problem? |
---|---|
Author | Enrico Cima |
Post date | 2002-09-25T09:39:23Z |
Dear List,
I've changed from Version 4.2Fr to 4.2Hj, but I've got the following
problem:
With "Fr" Version the following Query worked:
SELECT
N_COLORE,
N_CODICE,
NOME,
CODICE_FORNITORE,
(SELECT COD_ABV FROM FORN_FILATO WHERE CODICE=BASE_COL.FORNITORE_ID) AS
COD_ABV,
(SELECT VALUTA FROM VALUTA_DB WHERE CODICE=(SELECT VALUTA FROM CAT_COSTI
WHERE CODICE=BASE_COL.N_CODICE
AND FORNITORE_ID=BASE_COL.FORNITORE_ID
AND DESC_CAT_TINT_ID=BASE_COL.DESC_CAT_TINT_ID
AND DATAI<=:D AND DATAF>=:D)) AS VALUTA,
(SELECT PREZZO FROM CAT_COSTI
WHERE CODICE=BASE_COL.N_CODICE
AND FORNITORE_ID=BASE_COL.FORNITORE_ID
AND DESC_CAT_TINT_ID=BASE_COL.DESC_CAT_TINT_ID
AND DATAI<=:D AND DATAF>=:D) AS PREZZO
FROM BASE_COL
ORDER BY N_COLORE
instead with version "Hj" I've got an Exeption Error also directly preparing
the statment from the IB_Query Editor.
If i Cut a part of the query, (SELECT VALUTA..... or SELECT PREZZO....)
The Query still works.
What I'm doing wrong?
Thanks For Your comments.
Best Regards to all list.
P.S.
I'm using CBUILDER5 and IB 6.0.
I've changed from Version 4.2Fr to 4.2Hj, but I've got the following
problem:
With "Fr" Version the following Query worked:
SELECT
N_COLORE,
N_CODICE,
NOME,
CODICE_FORNITORE,
(SELECT COD_ABV FROM FORN_FILATO WHERE CODICE=BASE_COL.FORNITORE_ID) AS
COD_ABV,
(SELECT VALUTA FROM VALUTA_DB WHERE CODICE=(SELECT VALUTA FROM CAT_COSTI
WHERE CODICE=BASE_COL.N_CODICE
AND FORNITORE_ID=BASE_COL.FORNITORE_ID
AND DESC_CAT_TINT_ID=BASE_COL.DESC_CAT_TINT_ID
AND DATAI<=:D AND DATAF>=:D)) AS VALUTA,
(SELECT PREZZO FROM CAT_COSTI
WHERE CODICE=BASE_COL.N_CODICE
AND FORNITORE_ID=BASE_COL.FORNITORE_ID
AND DESC_CAT_TINT_ID=BASE_COL.DESC_CAT_TINT_ID
AND DATAI<=:D AND DATAF>=:D) AS PREZZO
FROM BASE_COL
ORDER BY N_COLORE
instead with version "Hj" I've got an Exeption Error also directly preparing
the statment from the IB_Query Editor.
If i Cut a part of the query, (SELECT VALUTA..... or SELECT PREZZO....)
The Query still works.
What I'm doing wrong?
Thanks For Your comments.
Best Regards to all list.
P.S.
I'm using CBUILDER5 and IB 6.0.