2

I wrote the program, but received unexpected results that me very much baffled

import firebirdsql
s1='''
create table CLIENTS
    (
       ID    INTEGER NOT NULL,
       COMPANY   VARCHAR(50),
       "LAST NAME"   VARCHAR(50),
       "FIRST NAME"   VARCHAR(50),
       "E-MAIL ADDRESS"   VARCHAR(50),
       "JOB TITLE"   VARCHAR(50),
       "BUSINESS PHONE"   VARCHAR(25),
       "HOME PHONE"   VARCHAR(25),
       "MOBILE PHONE"   VARCHAR(25),
       "FAX NUMBER"   VARCHAR(25),
       ADDRESS   BLOB SUB_TYPE 1,
       CITY   VARCHAR(50),
       "STATE/PROVINCE"   VARCHAR(50),
       "ZIP/POSTAL CODE"   VARCHAR(15),
       "COUNTRY/REGION"   VARCHAR(50),
       "WEB-SITE"   VARCHAR(25),
       NOTES   BLOB SUB_TYPE 1,
       INCLUDING   BLOB,
       CONSTRAINT PK_CLIENTS_ID PRIMARY KEY(ID)
    );
'''
conn=firebirdsql.create_database(host='localhost', database='test1.fdb',
        user='sysdba', password='masterkey')
cur=conn.cursor()
cur.execute(s1)
conn.commit()
conn.close()

As a result the database test1.fdb isn't created. I also tried to use a line of creation of a database

conn = firebirdsql.connect(dsn='localhost/3050:/test1.fdb', user='sysdba',
    password='masterkey'), but result is same.
4

0 回答 0