Actuarial Outpost
 
Go Back   Actuarial Outpost > Actuarial Discussion Forum > Software & Technology
FlashChat Actuarial Discussion Preliminary Exams CAS/SOA Exams Cyberchat Around the World Suggestions

US HEALTH ACTUARIAL JOBS

Reply
 
Thread Tools Display Modes
  #1  
Old 06-05-2007, 06:09 PM
notreallyme's Avatar
notreallyme notreallyme is offline
Member
CAS
 
Join Date: Dec 2002
Posts: 17,818
Default Access (Oh Oh my files got big!)

I have created a Access DB that allows me to do what needs to be done.

Right now I get the data from the client and use that.

I recently found out I can get the data directly from the Gov't. Which means instead of having one clients data for one year I have everyones data for 6 years.

There are approximately 20 text files that are 1 GIGABYTE each. What is the best (or a way that will work) to access these DB's (text files).

Can I query them through Access to pull data as needed? (That should be somewhat managable, but I am concerned about the time to run the queries, and I would have to figure out how to query off a TXT file )

We do have a SQL server for the RMS stuff, that is an option if it needs to be. Then I'd have to deal with ODBC connections. Not sure how fast or slow that would be.
I ma somewhat familiar with linking to EDM's and RDM's from RMS, Could I set it up like that? (Not that I know that much about the background of those things).

I need to query off the data often and run analyses from the queried data, the queries vary but are Generally by State and a LOB.

Any help is appreciated.

[[If necessary I will hire a temp to set up the DB, we should only get new data each year]]
__________________
Only true outliers:

succeed without lots of work
fail in spite of hard work

(paraphased from Sheba)
Reply With Quote
  #2  
Old 06-05-2007, 06:14 PM
E. Blackadder's Avatar
E. Blackadder E. Blackadder is offline
Member
 
Join Date: Sep 2001
Location: Not far from US 1.
Favorite beer: Beer?! Blech. But Dad likes Dortmunder Union.
Posts: 20,778
Blog Entries: 1
Default

If you can't link tables, then you still have some options.

You could try reading the big files one line at a time with VBA, and spliting out (or just selecting) the inputs based whether the record is interesting to you. I could try digging up some code where I did this a few years back.

SAS is an option, if it's an option. Foxpro might be an option, too.
__________________
If once a man indulges himself in murder, very soon he comes to think little of robbing; and from robbing he comes next to drinking and Sabbath-breaking, and from that to incivility and procrastination. Once begun upon this downward path, you never know where you are to stop. Many a man has dated his ruin from some murder or other that perhaps he thought little of
at the time.
Reply With Quote
  #3  
Old 06-05-2007, 06:17 PM
notreallyme's Avatar
notreallyme notreallyme is offline
Member
CAS
 
Join Date: Dec 2002
Posts: 17,818
Default

Quote:
Originally Posted by E. Blackadder View Post
If you can't link tables, then you still have some options.
I think I could link tables. Link from Text Files? I have no idea how, link from Access tables?

Would that mean create 20 Access Db's?
__________________
Only true outliers:

succeed without lots of work
fail in spite of hard work

(paraphased from Sheba)
Reply With Quote
  #4  
Old 06-05-2007, 07:19 PM
IMP's Avatar
IMP IMP is offline
= I Must Pass
 
Join Date: Mar 2004
Location: in my pants, and yours
Studying for drinking
Favorite beer: blue moon....cuz i'm a female
Posts: 30,388
Blog Entries: 11
Default

don't forget to compress your database files...there's tons of unused wasted space in each file/database
__________________
Quote:
Originally Posted by Patience View Post
that's why they invented doggy style
Reply With Quote
  #5  
Old 06-05-2007, 07:58 PM
notreallyme's Avatar
notreallyme notreallyme is offline
Member
CAS
 
Join Date: Dec 2002
Posts: 17,818
Default

Quote:
Originally Posted by IMP View Post
don't forget to compress your database files...there's tons of unused wasted space in each file/database
They are text files at the moment, and still over 2 GIG (in some cases).
__________________
Only true outliers:

succeed without lots of work
fail in spite of hard work

(paraphased from Sheba)
Reply With Quote
  #6  
Old 06-05-2007, 08:36 PM
MountainHawk's Avatar
MountainHawk MountainHawk is online now
Member
CAS AAA
 
Join Date: Dec 2001
Location: Salem, MA
Studying for Nothing!!!!
College: Lehigh University Alum
Favorite beer: Yuengling
Posts: 55,620
Default

I think you can link to a text file, as long as it's in 'database format'.

Are they csv?
__________________


"I am a most unhappy man. I have unwittingly ruined my country. A great industrial nation is now controlled by its system of credit. We are no longer a government by free opinion, no longer a government by conviction and the vote of the majority, but a government by the opinion and duress of a small group of dominant men." -- Woodrow Wilson

It doesn't matter who you vote for, the government always gets in. -- Elizabeth May

???? Jan 20: Freedom for the Bill of Rights

1 2
Reply With Quote
  #7  
Old 06-05-2007, 09:15 PM
notreallyme's Avatar
notreallyme notreallyme is offline
Member
CAS
 
Join Date: Dec 2002
Posts: 17,818
Default

Quote:
Originally Posted by MountainHawk View Post
I think you can link to a text file, as long as it's in 'database format'.

Are they csv?
Txt and they don't have headers. (Though I do have the 'key'). i.e. Characters 1-2 are Field1 Format String, Characters 3- 6 are Numerical, etc.
__________________
Only true outliers:

succeed without lots of work
fail in spite of hard work

(paraphased from Sheba)
Reply With Quote
  #8  
Old 06-05-2007, 09:25 PM
Random Poster's Avatar
Random Poster Random Poster is offline
Member
CAS
 
Join Date: Aug 2005
Studying for nothing!
Posts: 2,533
Default

Quote:
Originally Posted by notreallyme View Post
I think I could link tables. Link from Text Files? I have no idea how, link from Access tables?

Would that mean create 20 Access Db's?
You may be able to link to all of the files within a single Access database. Working with files this large could be more than Access can handle though.

To create a linked table, just right-click anywhere in the white space of the Tables tab in the database window and select Link Tables. Change the file type to Text Files, select a file and then follow the wizard. This will work with delimited (CSV) or fixed width files.

Access 97 had a file size limit of 1GB. This limit doubled with newer versions. I do not think you will be able to directly link to a file that exceeds this limit.

There is a way around this though. If you create the link using a smaller file that has the correct structure and then replace the small file, the link should still be valid.

Running queries off of these tables could be painfully slow though.

HTH,
RP
__________________
Surprisingly, not a mute.
Reply With Quote
  #9  
Old 06-06-2007, 10:00 AM
Steve Grondin Steve Grondin is offline
Member
SOA AAA
 
Join Date: Nov 2001
Posts: 3,630
Default

Be stingy in your data types. If you have a nine byte number with decimal places, use integer and "remember" the decimal places elsewhere.

If you have a date-time field and you only care about the date, you can use integer for YYYYMMDD if you don't do anything other than simple comparisons. Day-differencing rountines would become difficult then.

You certainly won't get a 20 to 1 compression with this, but it can help. SQL has more data-type options to do these kind of tricks with (not to mention no problem with the 2 gig limit).
Reply With Quote
  #10  
Old 06-06-2007, 11:16 AM
vchagas's Avatar
vchagas vchagas is offline
Member
 
Join Date: Jan 2007
Location: Lisbon, Portugal
Studying for Solvency II
Posts: 286
Default

There are several different ways to do what you want, with Access or with other DBMS.

I'm assuming you don't want to redo your access queries.

With Access, my approach would be to import each TXT table into a separate Access DB and then link them to the master Access DB (that way you can leverage you size limit from 2GB to 2GB for each MDB file.
Cons: it will probably be to heavy for Access to handle (too slow)

With other DB, import the TXT files into SQL Server (easiest way to avoid the 2GB size limit) and link each table to Access.

Redoing your queries in another commercial software (that i'm used to work with):
1st choice : SAS
2nd choice : Visual Fox Pro (2GB limit for each DBF file)

Redoing your queries in another free/open source software (that i'm used to work with):
1st choice : SQLite
2nd choice : MySQL
you can use these two as a backbone for access instead of SQL Server.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


All times are GMT -4. The time now is 08:04 AM.


Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
*PLEASE NOTE: Posts are not checked for accuracy, and do not
represent the views of the Actuarial Outpost or its sponsors.
Page generated in 0.51619 seconds with 7 queries