Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

AW: select count(*) from (select * from tab): msg#00376

db.maxdb

Subject: AW: select count(*) from (select * from tab)

I don not know any database where you can do this in the described way.
If you want this functionality than you have to use dynamic SQL. I not shure if
SAP DB has the "execute immadate" command like Oracle. The simplest way is to
create the necessary queries in your application.

Jan

-----Ursprungliche Nachricht-----
Von: sapdb@xxxxxxxxx [mailto:sapdb@xxxxxxxxx]
Gesendet: Freitag, 24. Oktober 2003 11:58
An: maxdb@xxxxxxxxxxxxxxx
Betreff: select count(*) from (select * from tab)


Hello

If I execute

select count(*) from (select * from tab)

I get the error 'General error;-2010 POS(1) Assignment impossible, char
value too long' if
tab is a table that contains a column of type long (that seems to be the
criteria).

[The above statement can always be made simpler (select count(*) from
tab) but sometimes (if for example the main query 'select * from tab' is
available) it is convenient to simply add 'select count(*) from(' +
origquery + ')'.]



Is that behaviour a bug or a feature?


The doc:
----------
-2010: Assignment impossible, char value too long

Explanation:

In an <INSERT statement> with a <QUERY EXPRESSION> or in an <UPDATE
statement>, the attempt was made to assign a character string to a
column of data type CHAR. This character string was too long. The error
message is returned for the first occurring value of excess length, not
while analyzing the maximum column lengths.

User Action:

Use SELECT ... WHERE LENGTH (<column name>) > <unsigned integer> to find
out the rows which are too long. The length of the corresponding column
can be increased by an <ALTER TABLE statement>
----------


Thanks,
Gabriel

--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe: http://lists.mysql.com/maxdb?unsub=jan.lolling@xxxxxxxxxxxxx

--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe: http://lists.mysql.com/maxdb?unsub=gcdm-maxdb@xxxxxxxxxxx




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
qplus.devel/200...    network.jabber....    debian.qa-packa...    encryption.gpg....    python.dabo.dev...    uclinux.devel/2...    science.mathema...    recreation.pesc...    kernel.ck/2004-...    mozilla.devel.e...    tex.latex.prosp...    ietf.multi6/200...    bbc.cvs/2002-11...    xfree86.newbie/...    jakarta.taglibs...    altlinux.hardwa...    comedi/2002-05/...    horde.bugs/2004...    games.diplomacy...    finance.e-gold....    web.dom.test-su...    lang.ruby.rails...    os.netbsd.devel...    video.gstreamer...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation