Friday, February 24, 2012

Array List in DB

Hi,
Is it possible to have a column as array in SQL Server 2000- similar to Oracle's varray. If yes, how?
rgds,
Kishoreyes, it is possible, but it is not recommended, because it will usually require table scans to access the contents|||I don't see a lot of point in Array fields when subtable give you the same functionality with less hassle and more control...|||subtable? what's a subtable? BOL is totally ignorant of that terminology|||I just haven't gotten around to writing that chapter yet. So busy posting on the forum, you know...|||What are either of you 2 talking about?

The only array stuff I've seen was in Ken Hendersons Book The Guru's Guide to SQL Server Stored Procedures, XML and HTML

Chapter 23...but that dealt with Dll's, ect...all very painful AND dangerous, if you weren't careful

Why, what do you need an array for?

PS A table is like an array anyway..you could use a table variable|||i believe blindman was actually just joking around

blindman, please let us know when you do this

as for my reply in post #2, yes, you can store an array as a comma-separated list of values in a single varchar column

i would've thought this would be obvious to any frequent poster here, and also why it's not a good idea|||as for my reply in post #2, yes, you can store an array as a comma-separated list of values in a single varchar column

That is not an array|||pedant!!

a lot depends on what programming language you have sitting on the front end

i know of several languages where you can simply assign the string to an array, and voila!

what would you call an array, please? and make sure you mention which language

;)|||You are both pedants!

When I get around to writing my Books Online chapter on subtables I will clearly define whether a comma-separated list is an array. Until then, you will just have to wait to find out.

And I am SERIOUS about this! ;)|||And I am SERIOUS about this! ;)Seriously what?

-PatP|||That is not an arrayTechnically, that's an unbounded vector. What's the difference though?

-PatP|||pedant!!

Hardly

a lot depends on what programming language you have sitting on the front end

Not really

i know of several languages where you can simply assign the string to an array, and voila!

Assign the string to an array..your words...the string is not an array

what would you call an array, please? and make sure you mention which language

An array is an object...pick you language...doesn't matter...they all behave the same way...|||brett, i know you can spell pedant (at least, so far), but do you actually know what it means?

"Assign the string to an array..your words...the string is not an array"

now that's pedantic!!|||God made google didn't he?

An array is more than data...Pat, I think you need to give up your "title" for Rudy...

How do you get the information rs.0 from a string for example?

Did you read Henderson's book?|||God made google didn't he?no, She didn't, and besides, that is such a non sequitur

An array is more than data...quite right, it is data plus relationship/sequencing

Pat, I think you need to give up your "title" for Rudy...if you are referring to "curmudgeon" then sorry, but you lead that race

Did you read Henderson's book?just once

a long time ago

:)|||Mathematically, an array is simply a bounded vector. Less formally, an array (http://searchstorage.techtarget.com/sDefinition/0,,sid5_gci211596,00.html) is a group of objects with the same attributes that can be addressed individually.

I ain't gonna give up my title without a fight! I'd be quite willing to add pedant (http://dictionary.reference.com/search?q=pedant) to my title though, if only they would let us (http://www.dbforums.com/t1070319.html)!

-PatP|||LOL, dude

which of the three subtitles did you wish to have?

1. One who pays undue attention to book learning and formal rules.
2. One who exhibits one's learning or scholarship ostentatiously.
3. Obsolete. A schoolmaster.

i'll cop to the last one only, i sure ain't the first

half the stuff i know i learned from you guys!

;)|||LOL, dude

which of the three subtitles did you wish to have?

1. One who pays undue attention to book learning and formal rules.
2. One who exhibits one's learning or scholarship ostentatiously.
3. Obsolete. A schoolmaster.

i'll cop to the last one only, i sure ain't the first

half the stuff i know i learned from you guys!

;)I'll just take pedant... Leave the determination of fit as an exercise for the reader ;)

Ich spreche sehr kliene Deutsche. You couldn't have learned half of what you know from me.

-PatP|||that's right

it's the other half

:cool:|||Is that like...

"I taught him everything I know...and he STILL doesn't know anything"

that is such a non sequitur

No it's not (although I am quite fond of them)...you were refering that I wouln't know what the word meant (which I didn't)...I mean A LOT of people who post here don't use Google...I use it all the time...soo...do I need to finish that thought?

if you are referring to "curmudgeon" then sorry, but you lead that race

Really? I'm not the one calling people pedant!!|||Really? I'm not the one calling people pedant!!really

you're being pedantic

that's far worse

;) :) :) :)|||You all sound like a pack of third-graders who have just been given dictionaries.

Seriously!|||I always sound like a third grader that just discovered a dictionary. I'm the only person I know who's cell phone has a collegiate dictionary on it!

Isn't pedant the word in the Pink Panther theme song?

I always thought that Orkin should license it as "dead-ant", but that would be too confusing with the aardvark on the same show... Ooops, I'm dating myself again, aren't I?

-PatP|||Those definitions for array sound very fishy. "a group of objects..."? That's a collection, which still uses the basic array concepts of storing and referencing data, but it's a collection. Don't you all remember your Intro to Computers 101? Isn't it just a linked list (I'll take double-linked list if that's what it is ;))?

No comments:

Post a Comment