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
 General SQL Server Forums
 New to SQL Server Programming
 Several dates for one row,Idea?

Author  Topic 

oren
Starting Member

2 Posts

Posted - 2009-03-26 : 06:16:34
I'm building a database of peoples entries to our place.
And each person has ID ,Name,Family Name exc...
My problem is that each person could have several entries to our place..
But I dont really have any good idea on how to store the data.
For example
ID NAME ENTRIES
00000 JOSH 15/3/09 , 22/3/09
00001 MORO 12/3/09 , 17/3/09

But I know that the data type can only store one data right?
My only Idea is to convert the data to string and store it In string data...
Any Other better option?
Thanks.

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-03-26 : 06:24:23
You should use a relation.
table1
id, name

table2
id,table1_id,entries



No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

oren
Starting Member

2 Posts

Posted - 2009-03-26 : 06:40:25
Ho indeed a great one
Thank you very much.
table2
id,table1_id,entry,comment
1 ,00001,20/04/08,entry
2, 00001,23/02/09,He ignored the rules be aware from him
3, 00005,03/03/08,entry

Thanks...
Go to Top of Page
   

- Advertisement -