|
well, imagine that:
char szDestination[] = { 0xFF, 0xFF };<br />
<br />
strncpy(szDestination, szSource, strlen(szDestination));
what do you think would be strlen() here?
-- modified at 22:38 Thursday 1st November, 2007
|
|
|
|
|
It's an improved random generator!
|
|
|
|
|
Steve Hansen wrote: It's an improved random generator!
ROFL
I ought to patent this!
Except if you do strncpy() as given you would most likely overwrite the return address or whatever comes next in enclosing function.
|
|
|
|
|
back in K&R C days this was always special:
memcpy( dest, src );
|
|
|
|
|
Seen the same dumb stuff to "clear a string":
sprintf( pcSomeStringBuffer, "%s", "");
<code>
strcpy( pcSomeStringBuffer, "" ); Peace!
-=- James Please rate this message - let me know if I helped or not!<HR> If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! See DeleteFXPFiles
|
|
|
|
|
Who the hell names database fields 'from' and 'to'? Need I say more?
|
|
|
|
|
This can be a lot of fun if you have to work with that
Cheers
You have the thought that modern physics just relay on assumptions, that somehow depends on a smile of a cat, which isn’t there.( Albert Einstein)
|
|
|
|
|
SELECT [SELECT], [FROM], [TO], [WHERE], [ORDER] FROM [WHERE] WHERE [WHERE]='GROUP BY OR HAVING'
This blanket smells like ham
|
|
|
|
|
This same schema just caught me again, as I have a policy of naming all my DAL parameters the exactly the same as the column names, which works Ok until a column that is called IsNew in a view is actually called 'new' in the table.
|
|
|
|
|
That reminds me of some fun I used to have (aeons ago) in Coral-66:
'FOR' FOR = 0 'TO' TO 'STEP' STEP 'UNTIL' UNTIL
'BEGIN'
BEGIN;
END;
'END'
something like that anyway - I can't remember the exact syntax
Phil
The opinions expressed in this post are not necessarily those of the author, especially if you find them impolite, inaccurate or inflammatory.
|
|
|
|
|
Database designers who don't have to write any SQL.
|
|
|
|
|
I also deal with gems like Tax%. Hey, 'like Tax%'...
|
|
|
|
|
I myself just created a table named Group. I also have a table named Parameter. And a field named When. But (so far) only I need to deal with them.
|
|
|
|
|
PIEBALDconsult wrote: But (so far) only I need to deal with them.
So you still have the chance to fix this foolishness before it gets into the real world...
-------------------------------------------
Don't walk in front of me, I may not follow;
Don't walk behind me, I may not lead;
Just bugger off and leave me alone!!
|
|
|
|
|
PIEBALDconsult wrote: And a field named When
And a field named "Poof"?
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
I once had to deal with a database that had dashes in the field names. That was the first time we ever had to lookup how to quote identifiers and were horrified to find that there was no standard. What worked on one system just made it a quoted string on another.
Meddle not in the affairs of dragons, for you are crunchy and taste good with catchup.
|
|
|
|
|
Not yet, waiting to hear back from the manufacturer.
|
|
|
|
|
Any advances on SET, DATE, YEAR and CLASS?
|
|
|
|
|
I had a chance to walkin to Axis Bank branch in the Chennai suburb on Saturday afternoon. The connectivity to the server seemed to be weak and hence the personal bankers attending to the customers even warned to each customer of the little delay and then were trying to maximum solve the queries as much as possible.
When my turn to the Personal Banker came and she was about to logon to the Menu Interface to my account in the application, she got a message
'java.lang.IllegalStateException ' and that seemed to be an indication of Connection dropped again. Isn't it a true WTF that without quality testing the banking product has come into deployments? And interestingly, after a few tries it logged on to present a 'Maximum License Reached' but the app was still functioning. The logon was showing the name of the application as Finacle .
This comes close to the heels when we discussed another Banking Issue [^]
sometime back regarding a bad database design of storing customer data in multiple tables.
-- modified at 6:01 Monday 29th October, 2007
|
|
|
|
|
Vasudevan Deepak Kumar wrote: Axis Bank branch
OOPS. I thought they have a good system. Their Iconnect facilities are fair enough.
|
|
|
|
|
N a v a n e e t h wrote: they have a good system
They do. They have a good customer care too. It is that WTF Finacle which is screwing things all along. Even in ICICI bank infinity which is powered by Finacle, when you logout it gives a JavaScript error since they use a ExecWB (Web Browser Object) to close the browser window, which is no longer supported.
|
|
|
|
|
Vasudevan Deepak Kumar wrote: It is that WTF Finacle
By infosis Right ? My friend is into it's implementation department, and he said it's a superb product.
|
|
|
|
|
N a v a n e e t h wrote: he said it's a superb product
Not to offend. But as long as the product or the application is in our cosy comfortable lap, it would sound and resemble that way. But there are integration paranoia, which any application should pass this litmus test to prove itself of its capabilities to the world.
N a v a n e e t h wrote: infosis
Infosys and its Stock Symbol is INFY right?
|
|
|
|
|
When I belive a system is good tested and more or less secure, than it should be a bank system, shouldn't it?
So seems to be my fault .
Cheers
You have the thought that modern physics just relay on assumptions, that somehow depends on a smile of a cat, which isn’t there.( Albert Einstein)
|
|
|
|
|
Fatbuddha 1 wrote: system is good tested and more or less secure, than it should be a bank system
True. That would be a very optimistic view.
Fatbuddha 1 wrote: seems to be my fault
Not necessarily. But those developers who brought out the buggy system had thier thought process the other way around -- Banking system is one of the systems.
|
|
|
|