Quote:>I am a new powerbuilder programmer and now encounter problem
>which may be silly. Anyway, can anyone help to answer this.
>My problem is that I have a table which contains two fields, x_axis and y_axis.
>This table is used for a line chat so there should be no primary key.
>However, I cannot insert any data into database if no primary key defined.
>I want to know how can I insert data into a table which has no primary key.
>I only use WATCOM as backend.
>Thank for any suggestion...
>Frankie
Irregardless of your DB you will not be able to insert into your keyless
table. It seems that PB wants to make sure there are no duplicates in
tables and makes it difficult for you to do this. One option is to put a
counter type key that increments for each add. You can create a new table
with a defined key in PB 4.0 using Data Pipelines. You may have to do
some SQL in order to generate all the keys. There may be a way of adding
data but I haven't see it. If you have Access 2.0 and the new ODBC
drivers (or VB Pro) you could do your data entry in Access and manipulate
the data through PB. It's probably easiest to just add the key in. Hope
this helps...
Dan
--
Jupiter Five Technologies
Contact: Daniel Doyon Phone: 617/623-6277
Specializing in Data Entry, Data Processing, CAD Drawing Conversion