Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error running SELECT query [CORE1668] #2093

Closed
firebird-automations opened this issue Dec 26, 2007 · 6 comments
Closed

Error running SELECT query [CORE1668] #2093

firebird-automations opened this issue Dec 26, 2007 · 6 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: pabloj (pabloj)

Duplicates CORE94

Hi, when trying to run a query on the standard employee.fdb:

select
e.emp_no, e.FIRST_NAME, e.LAST_NAME,
p.proj_name
from
employee e, project p left outer join EMPLOYEE_PROJECT ep
on e.EMP_NO = ep.EMP_NO and p.proj_id = ep.PROJ_ID;

I get the following error:

***IBPP::SQLException***
Context:Statement::Fetch
Message: isc_dsql_fetch failed.
SQL Message: -508
The cursor identified in the update or delete statement is not positioned
on a row.

Engine Code: 335544348
Engine Message: no current record for fetch operation

Firebird version is 2.1 beta and Flamerobin 0.8.3.1596 unicode.
This is what comes out from Flamerobin, but it's a Firebird issue, the same happens from the command line client (SQL Message: -508), I can get the explain plan of the query so it should be ok.
Could you please take a look at this?
Regards (and an happy new year ;-))

@firebird-automations
Copy link
Collaborator Author

Commented by: pabloj (pabloj)

A little background info, I'm trying to retrieve all employees and their projects (if available) this query works fine but I thnk that the previous one should not crash that way

SELECT
a.emp_no, a.FIRST_NAME, a.LAST_NAME,
CASE
WHEN ep.emp_no || ep.PROJ_ID IS NULL THEN ' didn''t take part in '
ELSE ' took part in '
END,
a.proj_name
FROM
(SELECT * FROM employee e, project p) a
LEFT OUTER JOIN
EMPLOYEE_PROJECT ep
ON a.EMP_NO = ep.EMP_NO AND a.proj_id = ep.PROJ_ID;

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

Link: This issue duplicates CORE94 [ CORE94 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Duplicate [ 3 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Workflow: jira [ 13743 ] => Firebird [ 14209 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

QA Status: No test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant