Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Site Related Forums
 The Yak Corral
 Insane Design

Author  Topic 

JimL
SQL Slinging Yak Ranger

1537 Posts

Posted - 2004-11-03 : 13:16:13
I was handed an Accounting Package to review.

In an attempt to keep individuals like me from interfacing or reverse engineering the software they have put in place the most Insane Design I have ever heard of.

Each Database is 3 numeric digits.
Table name is 4 numeric digits.
Column is 5 Numeric digits.
View name is 6.
Function Is 7.
Sp Is 8.

You need a code book to tell what is what.
This would probably triple their software engineers design time.

What are they Nuts?




Jim
Users <> Logic

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2004-11-03 : 13:20:46
no just overly paranoid...

Go with the flow & have fun! Else fight the flow
Go to Top of Page

robvolk
Most Valuable Yak

15732 Posts

Posted - 2004-11-03 : 13:30:38
If they used some kind of software modeling program, they could design the database and code using any names they like, and the code generator could rename them to something else entirely. There are code obfuscators that do something similar.

Of course, you can always run Profiler when performing certain tasks in the application to determine exactly what all of that crap does.

And they can't be THAT smart, they didn't put in any foreign keys.
Go to Top of Page

MichaelP
Jedi Yak

2489 Posts

Posted - 2004-11-03 : 13:47:38
Security by obsceurity!

Michael

<Yoda>Use the Search page you must. Find the answer you will.</Yoda>
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2004-11-03 : 15:40:37
They probably develop with proper names but with prefixes like
d_, s_, fn_, vw_, col_.
Then for release just run an app on all the scripts to get the names into a lookup table then rename them all.

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2004-11-03 : 16:43:06
imagine if they didn't do that, though. if the developers were forced to use codes the whole time.

that would be pretty funny. Imagine debugging THAT one !

- Jeff
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2004-11-03 : 23:08:19
quote:
Originally posted by JimL


What are they Nuts?

Jim
Users <> Logic



No, just territorial, lol

--------------------
keeping it simple...
Go to Top of Page

elwoos
Master Smack Fu Yak Hacker

2052 Posts

Posted - 2004-11-04 : 04:37:26
It didn't come from the UK did it?


steve

To alcohol ! The cause of - and solution to - all of life's problems
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2004-11-04 : 05:17:32
quote:
Originally posted by elwoos

It didn't come from the UK did it?


steve

To alcohol ! The cause of - and solution to - all of life's problems



lol,was that a subliminal question? ha ha ha, have you taken up kristen's offer?

--------------------
keeping it simple...
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2004-11-04 : 09:29:33
Anyone ever see any peoplesoft crap?



Brett

8-)
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2004-11-04 : 09:36:29
JDEdwards has table names like F0901, F0411, F0101 and column names like ABAN8, ABALP, GMOBJ. Absolutely horrible!

but many of these older systems have their "relational" database structures derived directly from COBOL text files back in the day when filenames could only be 8 characters long.

What is worse is -- no one will buy a new, truely relational accounting system because they are not "established". People feel comfortable with the stuff that's been around since the 80's. The problem is, the old stuff is really horrible, layer upon layer of patches and updates and web interfaces and XML and so on, all basically covering the same structure they designed back in 1983.

- Jeff
Go to Top of Page

JimL
SQL Slinging Yak Ranger

1537 Posts

Posted - 2004-11-05 : 13:14:47
This thing is from best software.

Man am I glad I do not have to deal with this crap.

I am having enough problems with their ACT software.

Must have had a SQL newbee working on this they used rowguid to create every Key constraint. Very messy indeed.

Jim
Users <> Logic
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2004-11-06 : 02:21:08
If I have to look up a row with a hardwired GUID is there some conversion penalty I can reduce?

I tend to do:

WHERE my_GUID = '14155377-DAF8-4DC2-A844-1F1BD4ED89DE'

but clearly SQL has to a) recognise that a GUID is required and b) convert it.

would
WHERE my_GUID = CONVERT(uniqueidentifier, '14155377-DAF8-4DC2-A844-1F1BD4ED89DE')
be faster? Is there a faster way? Take the "-" out so a few less characters to process?

Kristen

Go to Top of Page

robvolk
Most Valuable Yak

15732 Posts

Posted - 2004-11-06 : 07:30:19
Ummmmm, you're converting a 38 character string on a what? 2 GHz machine? It would take something much less than one-millionth of a second for it to convert that literal string to an actual GUID. And in your example it would only do it once.

Now, if you have a varchar column that stored GUID strings, and you had to convert all the values in that column, that would slow down performance compared to using a real GUID column.
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2004-11-06 : 16:55:59
Yeah, I appreciate that; however, we have plenty of SProcs that are hammered all the time that do this. Its only a microsecond, but it mounts up - and if there is an easy "most efficient way" I'd like to adopt it.

Kristen
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2004-11-06 : 18:00:53
The query will look at the datatypes involved and as uniqueidentifier has higher precedence than varchar will convert implicitly. Shouldn't make any difference if you do the explicit convert.

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2004-11-07 : 03:10:24
Cheers Nigel, I can adopt sleep-easy mode now!

Kristen
Go to Top of Page

Auric
Yak Posting Veteran

70 Posts

Posted - 2004-11-08 : 14:44:40
Sounds like MS Great Plaines (er however you spell that)

Good luck finding out where something is stored....
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2004-11-08 : 15:01:47
quote:
Originally posted by jsmith8858

but many of these older systems have their "relational" database structures derived directly from COBOL text files back in the day when filenames could only be 8 characters long.



Not true...8 bytes is the length of a PDS Member name....

Now it is true that I keep an 8 byte mnemonic for each and every object....but that's for ease of administration...

Tables can be a whopping 18 bytes in DB2....





Brett

8-)
Go to Top of Page
   

- Advertisement -