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

/cwms-data/levels Returns System Error when using * #873

Open
krowvin opened this issue Sep 6, 2024 · 2 comments
Open

/cwms-data/levels Returns System Error when using * #873

krowvin opened this issue Sep 6, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@krowvin
Copy link
Collaborator

krowvin commented Sep 6, 2024

COMMAND

curl -X 'GET' \
  'https://T7HOST:TCPORT/swt-data/levels?level-id-mask=*&office=SWT&begin=2024-09-06T00%3A00%3A00-05%3A00&end=2024-09-06T00%3A00%3A00-05%3A00&format=json&unit=EN' \
  -H 'accept: */*'

ERROR

 Caused by: Error : 20998, Position : 0, Sql = BEGIN :1 := "CWMS_20"."CWMS_LEVEL"."RETRIEVE_LOCATION_LEVELS_F" (:2 , :3 , :4 , :5 , :6 , :7 , :8 , :9 ) ; END;, OriginalSql = { ? = call "CWMS_20"."CWMS_LEVEL"."RETRIEVE_LOCATION_LEVELS_F" (?, ?, ?, ?, ?, ?, ?, ?) }, Error Msg = ORA-20998: ERROR: ORA-06512: at "CWMS_20.CWMS_ERR", line 59
ORA-06512: at "CWMS_20.CWMS_LOC", line 5726
ORA-06512: at "CWMS_20.CWMS_LOC", line 5691
ORA-06512: at "CWMS_20.CWMS_LOC", line 5754
ORA-06512: at "CWMS_20.CWMS_LOC", line 216
ORA-06512: at "CWMS_20.CWMS_LOC", line 191
ORA-06512: at "CWMS_20.CWMS_LOC", line 167
ORA-06512: at "CWMS_20.CWMS_LOC", line 252
ORA-06512: at "CWMS_20.CWMS_LEVEL", line 12915
ORA-06512: at "CWMS_20.CWMS_ERR", line 59
ORA-06512: at "CWMS_20.CWMS_LEVEL", line 13402
ORA-20998: ERROR: Alias (177296D0) matches more than one location.
ORA-06512: at "CWMS_20.CWMS_ERR", line 59
ORA-06512: at "CWMS_20.CWMS_LOC", line 5726
ORA-01422: exact fetch returns more than requested number of rows
ORA-06512: at "CWMS_20.CWMS_LOC", line 5691
ORA-06512: at "CWMS_20.CWMS_LOC", line 5754
ORA-06512: at "CWMS_20.CWMS_LOC", line 216
ORA-01403: no data found
ORA-06512: at "CWMS_20.CWMS_LOC", line 191
ORA-06512: at "CWMS_20.CWMS_LOC", line 167
ORA-06512: at "CWMS_20.CWMS_LOC", line 252
ORA-06512: at "CWMS_20.CWMS_LEVEL", line 12915
ORA-06512: at "CWMS_20.CWMS_LEVEL", line 11682
ORA-06512: at line 1

                at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:513)
                ... 85 more

Side Note:

The default in the levels/ endpoint in swagger fails and returns text output with "failed to parse json"

In the client you can specify "format=json" and it will work. Swagger does not like having accept (default in swagger) and format set.

@krowvin krowvin added the bug Something isn't working label Sep 6, 2024
@krowvin
Copy link
Collaborator Author

krowvin commented Sep 6, 2024

@DanielTOsborne and I were working on this / discussing it

@rma-rripken
Copy link
Collaborator

I don't understand your comment 'In the client you can specify "format=json" and it will work'. In the example you posted format=json is set

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants