Search these areas:
Support Forums
Product Info

-DataWeb: What's New
-Creating an Application
-The DataWeb Designer
-Application Management
-Data Tables
-Data Tables
-Data Analysis
-Object Model
-Full-Text Search
-Domain and Email Hosting
-HotBlock Modules
-Account Management
-New Responsive UI Module

DataWeb Help
Support Forums
Script Library
Knowledge Base

Home > Support

Support Forum

Any Nifty ideas on speeding Data Entry??
jaime_mauro asked:
Hi Again,

I have a need to enter a slew of data from various spreadsheets for a product maintenance application. The data is generally stored in one table and some of the fields are really lookups to/from other tables e.g. a customer name.

Can you advise me on how to write a script to load data from an excel spreadsheet's individual cells into similar 'fields' on a westside/dataweb table? and/or to have a button I can push to repeat the previous entry?

Please note: I have tried the import facility already and it does not work to my liking for 2 reasons--1. I need to load the data into a table that already has data and I do not want to tamper with existing records---import ERASES existing data in my experience and 2. Any lookup fields/relationships within the table I am importing into get's as though the only thing the import will allow is the creation of a new table based on cells in the spreadsheet or access db, a useful utility, but not what I'm looking for hear.

Any help appreciated.
  dougl responded:
  1. import the data into a single table.
2. data transfer data from the new imported table to your existing table.

You'll need to find some way to figure out how to resolve the lookup fields to their appropriate records in the lookup tables. What I usually do is:

assume you have two tables:
the master table contains all of your original data. This is the table you'd like to maintain and add to

the import table contains the next batch of imported data. Data from this table will be added to the master table.

Also assume:
The master table has a field named "LookupField" which is a lookup to the table "LookupTable"

The import table has a field named "WantsToBeALookupField" which contains values that corrospond to records in "LookupTable".

1. create a new field on the master table. Name it "WantsToBeALookupField".
2. data transfer all of your data from the import table.
3. write a script that queries the master table for records where "WantsToBeALookupField" is not null and "LookupField" is null.
4. walk through that resultset. For every record returned, query "LookupTable" for the primary key value of the record that matches "WantsToBeALookupField" and place this value in "LookupField". You may also want to NULL out "WantsToBeALookupField" as you go along.
  jaime_mauro responded:
  Thanks Doug, I'm sure this will help...I'm curious though, if I knew ahead of time what the appropriate primary key values in the lookup tables were, could I just load these into my import table and then data transfer them over to master table? or would this too, mess up my lookups?  
  dougl responded:
  Oh yeah. This will work. The lookup field only requires an integer (in default-style tables). It doesn't care how you inserted the integer.

It doesn't even care if the integer relates to a real record on the lookup table.
  dougl responded:
  DataWeb considers this issue closed.
If you have additional questions or comments about this issue, please open it again.
If you have questions about a different topic please open a new support question.

DataWeb Support
  Please Log On
or create your own DataWeb Account.
Affiliate | Partner | Terms of Use | Privacy Policy | Contact Us | Pricing | Bring DataWeb In-House    
DataWeb, 720 North 10th Street, A #145, Renton, Washington 98057 *425-583-5970* Fax 484-770-4706* Email Us