We help IT Professionals succeed at work.

SQL Error when creating a view in progress

Medium Priority
1,476 Views
Last Modified: 2013-12-25
I am trying to create the following view in proggress :

create view pub.binqtys as
select pub.partbin.partnum, sum(pub.partbin.onhandqty) as sumqty
from pub.partbin group by
partnum;
COMMIT;

And i receive the following error:

result:

=== START Tue Feb 17 16:56:12 GMT 2009 ===
create view pub.binqtys as
select pub.partbin.partnum, sum(pub.partbin.onhandqty) as sumqty from pub.partbin group by partnum;

=== SQL Exception 1 ===
SQLState=HY000
ErrorCode=-20074
[DataDirect][OpenEdge JDBC Driver][OpenEdge] View column list must be specified as expressions are given (7579)
=== END Tue Feb 17 16:56:12 GMT 2009  Processing time = 0.031 secs ===

=== START Tue Feb 17 16:56:12 GMT 2009 ===
COMMIT;

=== END Tue Feb 17 16:56:12 GMT 2009  Processing time = 0.000 secs ===

=== SUMMARY: SQLStatements =2.  Errors = 1.  Warnings = 0.===


Thanks



Comment
Watch Question

Billing Engineer
CERTIFIED EXPERT
Most Valuable Expert 2014
Top Expert 2009
Commented:
what about this:
create view pub.binqtys (partnum, sumqty)
as
select pub.partbin.partnum 
   , sum(pub.partbin.onhandqty) 
from pub.partbin 
group by pub.partbin.partnum;

Open in new window

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
Thanks
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.