Datacom SQL -148 SQLCODE
search cancel

Datacom SQL -148 SQLCODE

book

Article ID: 203568

calendar_today

Updated On:

Products

Datacom/DB Datacom/AD

Issue/Introduction

CA Datacom SQL query fails with:

SQLCODE = -148, SQLSTATE=21000                             
MESSAGE = SUBQUERY AT LVL 1 NBR 1 RETURNED MORE THAN 1 ROW 

Environment

Release : 15.1

Component : CA DATACOM SQL

Resolution

CA Datacom Messages Guide documents SQLCODE -148:

-148 - SUBQUERY AT LVL aaaa NBR bbbb RETURNED MORE THAN 1 ROW

Reason:
For proper evaluation, the subquery in question must return no more than one row. The level of nesting for the subquery and the total number of levels of nesting are displayed in the message text. However, it has been determined that the subquery returned more than a single row.
The SQLSTATE that equates to this SQL return code is 21000.

Action:
Ensure that the subquery is specified in such a way as to return only one row.

 

Additional Information

This is an SQL restriction. Cannot set a single column value to multiple sub query values.

Refer to CA Datacom Messages SQL Codes for the set of codes.