I am using Delphi 6. I am rather new to this.
Whenever an empty MySQL date field (not really empty but 000-00-00) is displayed in db-aware controls (dbgrid and dbedit), it is displayed as '12/30/1899'. Is there way to make the controls display and empty/blank field instead of 12/30/1899 ?
Oops. Thought I included that ......
Warning | 1261 | Row 4225 doesn't contain data for all columns
Warning | 1261 | Row 4226 doesn't contain data for all columns
Warning | 1261 | Row 4227 doesn't contain data for all columns
Warning | 1261 | Row 4228 doesn't contain data for all columns...
I get an error when importing a csv file.
Query OK, 16394 rows affected, 176 warnings (0.27 sec)
Records: 16394 Deleted: 0 Skipped: 0 Warnings: 176
LOAD DATA LOCAL INFILE '/path/janfeb2008.csv'
into table tablename
fields terminated by ','
lines terminated by '\r\n'
(
ticket_number,
title...
I'm writing an application in Delphi 6. Last time I saved the project everything was working, now when loading I get an error.
When loading form1.pas I get 'Invalid property value'.
How can I determine what is causing this?
I am rather new to this so please keep that in mind when answering...
I am beginning to suspect that is were my problem lies.
I'm not using ODBC, I am using a freeware query component in conjunction with libmysql.dll.
I have been hoping to accomplish this with out OBDC or BDE. As long as I don't use calculated fields on the mysql side, everything is great.
Hi Andrew,
Actually , I was executing the query before hitting the button to update the form caption. I was doing it in another button. It seems to execute alright, I have a datasource and datagrid attached to the query, I see the field 'priority' listed in the grid.
the datagrid looks like...
this is the code that I am using to build the query
datamodule2.mysqldataset2.active:=false;
datamodule2.mysqldataset2.sql.clear;
datamodule2.mysqldataset2.sql.add('select ');
datamodule2.mysqldataset2.SQL.add('priority,avg(datediff(date_resolved,date_occurred)) as AverageDays ')...
Hi Leslie,
Thanks for your response. I'm still having a problem accessing this data. The query executes as it shouold but when I attempt to access the field 'AverageDays' , I am told field does not exist.
Does the field have to exist in the table in the database?
I am execute the following query:
select priority,(avg(datediff(dateresolve,dateoccurred)) from table group by priority.
if I execute this in mysql I get:
+----------+--------------------------------------------+
| priority | avg(datediff(date_resolved,date_occurred)) |...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.