Member Login

Username
Password
Forget Password
New Sign Up
Search Forum

Buy Support
Incidents

If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:

Click Here
If you can't login and post questions or you are having trouble viewing forum posts:
Click Here
Callback
Support

If you live in USA, UK, Canada, Australia or New Zealand, you can leave us details on your question and request us to call you back and discuss them with you personally  (charges apply).

Click Here
 
Buy Support
Incidents
If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:
Click Here

Forum : FlexODBC driver does not support the requested NULL properties error on insertSearch Forum

Forum Home > FlexODBC - ODBC Driver for DataFlex Embedded DBMS > FlexODBC SQL Support Forum

 New Topic 
 
 Post Reply 
[1]  
 FlexODBC driver does not support the requested NULL properties error on insert 
 Author   Message 
  jambai 
  
 Group: Members 
 Posts: 12 
 Joined: 2007-07-21 
 Profile
 Posted : 2008-03-06 10:43:12
I am getting the below error message when trying to add a record into a DATAFLEX table (CaryInfo). When I run the query against the DF Table through MS access its getting inserted. The error happens with his table only.
 
I am able insert records to the remaining tables in the same way
 
Error Number :-2147217887
Error Description : ODBC driver does not support the requested properties
 
Dim strInsDFCI As String
Dim rsDFCI As New ADODB.Recordset
                       
strInsDFCI = "INSERT INTO CARYINFO (" & strDFCIColName & ") VALUES(" & strDFCIVal & ")"
'cnDF.Execute strInsDFCI
rsDFCI.Open strInsDFCI, cnDF, adOpenKeyset, adLockOptimistic
Thanks
Jambai
 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-03-06 11:08:41
Check that CARYINFO isn't a DataFlex (one record) System File or a READ ONLY datafile. As I don't know the value of strDFCIColName it's hard to work out what property is causing the error here. 

  Top 
  jambai 
  
 Group: Members 
 Posts: 12 
 Joined: 2007-07-21 
 Profile
 Posted : 2008-03-06 11:12:44

The below is my insert query

INSERT INTO CARYINFO (ADJUSTER,CLAIM_NUM,RECORDS,COVERAGE1,COVERAGE2,
EMPLOYER,SAK#YEAR,SAK#ORDER,DEF_NUM,ORDERRECNO,DATE_AGREED,CASE_NUM,SQL_ID)
VALUES('Elizabeth Wojcik','E1021470','N', {d '2001-11-13'},NULL,
'154958','8','80149','2','256101',NULL,'POM 0260754','235664')

Thanks

Jambai

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-03-06 11:22:01
You can't insert a NULL into a DataFlex table, use '' for strings and 0 for numerics instead. 

  Top 
  jambai 
  
 Group: Members 
 Posts: 12 
 Joined: 2007-07-21 
 Profile
 Posted : 2008-03-06 11:38:46

('Elizabeth Wojcik','E1021470','N',{d '2001-11-13'},'','154958','8','80149','2','256101','','POM 0260754') i tried with ' ' for date null but still getting the same error

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-03-06 11:47:19
For Date fields you either have to leave the column and value out of the INSERT statement or set a default date that's ignored in operations like {d'1900-01-01'}. Numeric fields must be inserted as numerics and not strings, ie: 1 not '1' 

  Top 
  jambai 
  
 Group: Members 
 Posts: 12 
 Joined: 2007-07-21 
 Profile
 Posted : 2008-03-06 11:54:26

Still I am getting the same error message

Please see my insert Query

INSERT INTO CARYINFO (ADJUSTER,CLAIM_NUM,RECORDS,COVERAGE1,COVERAGE2,EMPLOYER,SAK#YEAR,
SAK#ORDER,DEF_NUM,ORDERRECNO,DATE_AGREED,CASE_NUM,SQL_ID)
VALUES('Elizabeth Wojcik','E1021470','N',{d '2001-11-13'},{d'1900-01-01'},'154958','8',
'80149','2','256101',{d'1900-01-01'},'POM 0260754','235664')

Thanks

Jambai

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-03-06 12:34:39

EMPLOYER, DEF_NUM and ORDERRECNO are numeric, the statement should be:

INSERT INTO CARYINFO (ADJUSTER,CLAIM_NUM,RECORDS,COVERAGE1,COVERAGE2,EMPLOYER,SAK#YEAR,
SAK#ORDER,DEF_NUM,ORDERRECNO,DATE_AGREED,CASE_NUM,SQL_ID)
VALUES('Elizabeth Wojcik', 'E1021470', 'N', {d '2001-11-13'}, {d'1900-01-01'},154958,'8',
'80149',2,256101,{d'1900-01-01'},'POM 0260754','235664')

 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to