Hi,
I have a table Log described as such:

+----------+-----------+------+-----+---------+-------+
| Field    | Type      | Null | Key | Default | Extra |
+----------+-----------+------+-----+---------+-------+
| rec      | int(1)    | YES  |     | NULL    |       |
| time     | int(10)   |      |     | 0       |       |
| ct       | char(100) | YES  |     | NULL    |       |
+----------+-----------+------+-----+---------+-------+

Notice that default for ct is NULL.
Now I have a ^ separated line in my file which I am loading via LOAD FILE.
This line MAY or MAY NOT have the corresponding ct value. So,
it could either be ....^www.yahoo.com^(ct value)  or .....^^.....(no ct
value).
I would like that when there is no ct value present in the line,
the ct value in Log table should stay as the default NULL....but it is not.
The value becomes '' i.e. a zero length string.

Any ideas on how can I keep it as NULL?

Any help is much appreciated.
Thanks in advance,

Bhavin.

sql, mysql, query.

Reply via email to