Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Another angle on this....
Thanks for your considered responses.....
"Jim Kennedy" <kennedy-family_at_attbi.com> wrote in message
news:7dOc8.25995$UT6.53933_at_rwcrnsc52.ops.asp.att.net...
> My guess at your poor performance on the row retrieval is that you are
> probably trying to simulate the client side cursor concept that sqlserver
> uses (bring all results to client and close cursor). They do this because
> of the locking problems sqlserver has. They don't complain about not
having
> multiversioning because they haven't heard of it in most cases. Since
> sqlserver doesn't work that way and the MS consultants will never answer
the
> question "I have a complex batch process that needs to process a large set
> of rows (eg millions) how do I do this without bringing the entire result
> set back at once?
You seem to be describing something different from my experience. I have to
confess that I haven't noticed this client-side cursor problem on any
platform. When retrieving large sets (BTW I'm tichy by you Oracle guys
standards, I think 50k records is large for one retrieval) I haven't noticed
a longer wait before the first one appears than I get when retrieving a
small set. Nor have I noticed client-side memory gobbling (other than the
obvious gobbling by my own app as it reads through the records if it needs
to cache all the data) that your observed behaviour would imply. Curious.
This merits some investigation. I'll send you the results if I notice
anything that might help you. I'm fairly sure that server side cursors
appeared in MSSQL some time before I started using it which makes your
consultants behaviour baffling.
> Once I got past the retrieve entire result set mantra the
> MS consultant (from MS) said he would get back to me. Never did. Try
> server side cursors, just rtetrieve what you need when you need it. Also
> use array fetches and bind variables and don't close the cursor, keep it
> open, change the bind variables and reexecute, much faster. (probably not
> doing that)
I use SQLBindCol, I only ask for the rows and columns that I want. Why would
I form SQL to request rows or columns that I don't want? I use the
array-fetch call in ODBC (to large measured benefit). I've tried all the
different cursor options that ODBC offers (even the ones that are no use to
me without recoding), they seem to make a slight difference of +-50% but
nothing like the order of magnitude that I need to even start moving towards
parity with other platforms. Thanks for the suggestions however.
>
> Really, if creating an index is that much of a problem then you have
larger
> problems.
I've never said creating an index is much of a problem. My schema has
hundreds of indexes in it. I now need to go through them all working out if
(a) I don't need an upper-case version (b) I can switch the Oracle version
of this index to pure upper-case or (c) I'm going to need both the natural
and upper-case versions. Poor decisions will make the app function less well
than it ought and I'm not required to make these decisions in other
platforms. Idiots like me need to be given the minimum of opportunities to
screw up.....
Then I have to modify my DDL generator and DB Metainformation that it works
on to indicate which indexes are going to be (a)/(b)/(c) when built on
Oracle client sites.
Its not the end of the world, I've worked round it. I'm paid to to that. Its
just a gripe.
> Since function based indexes are good for other uses besides
> upper or lower on a text column. I would rather have them implimented
this
> way than not be able to search case sensitive or use function based
indexes
> for other purposes.
I take your point. Function based indexes look great. Curiously every sample
I've seen of their use in tutorials etc has been to upper-case a text field;
I wonder why that would be?<G> Case sensitive searches have not figured
largely in my life . I didn't notice that I couldn't do them in the dbs that
I'd set up.....When installing other platforms you can choose whether you
want case-sensitive collation or not. Oracle doesn't offer this choice and
would be a better app if it did. As I say, minor stuff.
>
> I've ported to 9 different back ends and sqlserver was the most
difficult -
> took 6 rewrites of the driver layer and 9 months, all the other databases
> took 30 days to add the functionality including qa time (1 engineer doing
> all the development). In the end it worked, but in comparison to
everything
> else it was not as stable. Granted this was 6.5, but everything is
> realative.
SQL Server 6.5 (at that time) was my second-toughest port after Oracle, but
then it was the first port that I did and I discovered my non-portable
stupdities doing it so I can't blame a lot of that time on SQL Server. To
accuse MSSQL6.5 of instability is to accuse M Schumacher of fast driving (7
and 2000 IMHO are much better though I've seen disagreements from DBAs on
this). Sybase AS was next, and easier, DB2 took under a day start to finish
(obviously not including qa!), then Oracle which has proved just a teeeensy
weeeensy bit harder which ran counter to my expectations. Probably like your
SQL6.5 experience.
>
> Jim
>
> "Heinz Kiosk" <no.spam_at_ntlworld.com> wrote in message
> news:yiMc8.91752$as2.14794568_at_news6-win.server.ntlworld.com...
> >
> > "damorgan" <dan.morgan_at_ci.seattle.wa.us> wrote in message
> > news:3C72A014.C8DCFDDC_at_ci.seattle.wa.us...
> > > 1. Defending the indefensible? Bug? Let me quote you from page 38 of
Tom
> > Kyte's book expert one-on-one
> > > Oracle.
> > >
> > > "The developer doing the conversion (from TransactSQL to Oracle) was
> > complaining that the SQL queries in
> > > Oracle returned the 'wrong' answer. The goal here was to find al of
the
> > rows in T where X was Null if
> > > some condition was not met or where x equaled a specific value if some
> > condition was met.
> > >
> > > The complaint was that, in Oracle, this query would return no data hen
> > L_SOME_VARIABLE was not set to a
> > > specific value (when it was left as Null). In Sybase and SQL Server,
> this
> > was not the case - the query
> > > would find the rows where X was set to a Null value. I see this on
> almost
> > every conversion from Sybase
> > > or SQL Server to Oracle. SQL is supposed to operate under tri-valued
> logic
> > and Oracle implements Null
> > > values the way ANSI SQL requires them to be implemented. Under those
> > rules, comparing x to Null is
> > > neither True or False - it is, in fact, unknown."
> > >
> > > So if complying with ANSI SQL is an indefensible bug I'll stand in for
> > Larry Ellison. >>Fire when ready!
> > Straw man again.... You do like them. I hope you didn't pay much for
that
> > book.<G>
> > I'm not complaining about Oracle returning no rows from comparisons with
> > Null value fields. Nor am I complaining that I can't have Nulls in
unique
> > keys. No db that I am aware of returns rows from null comparisons and
the
> > reference above to SQL Server doing it is mistaken. It definitely
doesn't.
> > Reading the snippet Tom Kyte has missed the point (deliberately?). He
> didn't
> > notice that all other db platforms actually distinguish between blank
and
> > null (correctly). Presumably he is some Oracle high-priest and I'll now
be
> > burnt at the stake for heresy.
> >
> > To repeat; I am complaining that Oracle turns blank strings into Nulls.
> That
> > is the indefensible behaviour. All of the rest is collateral damage
> > resulting from the fact that Oracle doesn't appear to understand that ""
> is
> > a valid value for a string field distinct from NULL. Lets put it another
> > way, would you still defend Oracle if integer zeroes were considered as
> > nulls and failed to match any query predicate other than "is null" and
> > integer zeroes couldn't be in a key and appeared last in sorted lists
etc.
> > Come on.
> >
> > You and Tom Kyte are in a hole thats so deep I can't see either of you
any
> > more, just the frenzied earth flying out the top. Stop Digging.
> > > ----------------------------------------------
> > > 2. BFD = Big ..... Deal
> > Thank you, I'll remember that.
> > However, its a big deal for me when porting a large app from another
> > platform. Did the developer who implemented quoted identifiers really
> think
> > that users would want to distinguish between columns named "Comment" and
> > "COMMENT" and "cOMMENT" and "CoMMENT"......? Not useful
> > > ----------------------------------------------
> > > 3. I've been using identity columns for years.
> > > What difference can't be implemented in 29 keystrokes?
> > > Be specific.
> > See my boring and pointlessly detailed rebuttal in another thread.
> > > ----------------------------------------------
> > > 4. Creating an index is a pain? Really? No doubt you'll never touch C
or
> > Java.
> > My main development is done entirely in C++. Its only a minor pain.
> > > ----------------------------------------------
> > > 5. Had you given an example I'd gladly comment. But, like CASE, I
> suspect
> > > you are expressing more your lack of knowledge of Oracle rather than
any
> > > inability of Oracle to perform some function.
> > Try decode (fieldvalue>4,0,otherfieldvalue,0) As it happens, most of my
> > gripe about this goes away as I can use CASE when fieldvalue>4 then 0
else
> > otherfieldvalue END
> > > ----------------------------------------------
> > > 6. Didn't appear in 9i. I use it in 8i.
> > > You stand doubly corrected.
> > Another Oracle user has told me that their documentation for 8i does not
> > mention it either. Out of interest, could you definitely create views
> using
> > CASE in 8i using PL/SQL? Thats what I wanted to do and failed for some
> > reason. Probably incompetence.
> > > ----------------------------------------------
> > > 8. No one uses Oracle "out of the box" any more than one builds a
house
> > with 2x4s.
> > > Nails and carpentry are required. The advantages come with a cost. The
> > cost of
> > > having to do real work and reading the manuals.
> > I've been pampered, the other db manufacturers built my house for me,
its
> a
> > bummer to have to build my own. <G>
> > So, optimised ODBC routines only managing to return 2.5% of the
> performance
> > of 4 other platforms (out of the box performance) is acceptable
> performance
> > for Oracle out of the box, cos "no-one uses it that way". As a clueless
> > whining stranger to the real work that you are familiar with any guesses
> at
> > how long it'll take me to solve this one? I need to know how long I'll
be
> > doing real work and when I can revert to my normal slothful condition.
<G>
<G>> > > > > 1. No multiversioning.
> > > > > >
> > > > > > Regards
> > > > >
> > > > > What your list clearly indicates to me is that you are totally
> > clueless as
> > > > > to what Oracle is.
> > > > Its not a database then? Damn.
> > > >
> > > > > Let me give you the reverse complaint list. One for
> > > > > which there is no work-around in SQL Server.
> > > > >
![]() |
![]() |