Search these areas:
Help
Support Forums
Product Info



Introduction
DataWeb: What's New
Creating an Application
The DataWeb Designer
Application Management
Data Tables
-Understanding Data Tables
-Creating a New Data Table
-Adding Fields to a Data Table
-Specifying a Primary Key
-Linking Tables with Lookup Fields
-Modifying a Field's Definition
-Merging Tables with Data Transfer
-Removing a Data Table
Data Tables
Views
Templates
Components
Data Analysis
Members
Security
Importing
Exporting
FTP
JavaScript
Object Model
Full-Text Search
Domain and Email Hosting
HotBlock Modules
Account Management
Glossary
New Responsive UI Module





DataWeb Help
Support Forums
Tutorial
Script Library
Knowledge Base

Home > Support

DataWeb User's Guide

Specifying a Primary Key
A data table's primary key is a field whose value uniquely identifies each record, i.e., row, in the table. A primary key field is usually an integer field, but it can be a text, date, or decimal field. The primary key field can never contain a null value.

Every data table in your DataWeb web application must have a primary key. When you create a new data table from scratch, the default primary key field will be an automatically-incrementing integer field named RowId.

Changing a Table's Primary Key
You can change a table's primary key as long as there's no data in the table. To specify a different field for the primary key, open the table's data folder and click on the .data file and then the Design tab to display the table's schema. Click the PrimaryKey tab to display a list of possible primary key fields. Select the desired field and click the Apply button.

Importing Tables from an Access Database
When you import a table from an Access database into your web, its primary key will be preserved in the resulting data table if it meets the following criteria:

•  The primary key field must consist of a single field. Primary keys comprised of multiple fields are not supported by the DataWeb engine.

•  The primary key field must have a data type that corresponds to the integer, text, date, or decimal data types supported by the DataWeb engine.
Affiliate | Partner | Terms of Use | Privacy Policy | Contact Us | Pricing | Bring DataWeb In-House    
Email Us