1. fb_user
  2. RO CSVI
  3. Friday, 02 December 2022
  4.  Subscribe via email
Hi there,
I am importing data with RO CSVI into a self made table in the Joomla database. Some of the data are 0 (zero). When I test-run ("voorbeeld";) the RO CSVI template I see that the zeros are listed (see screenshot). When I look in the database, I see that the 0's (zeros) have been dropped (see screenshot). I have checked that "Skip empty custom fields" is set to "No".
I am including the CSV-file, the log file and the import template in this ticket.
Can you tell me how I can get the import to include the zeros?

Thank you,

Thom
Attachments (5)
Accepted Answer
Accepted Answer Pending Moderation
Hi there,
I checked what we did in a previous project. We then also made a table ourselves. The numerical fields were then INT. So that is what I changed it to and it all worked ok.

Thanx for your time and input.

Thom
  1. more than a month ago
  2. RO CSVI
  3. # Permalink
Accepted Answer Pending Moderation
Hello Thom,
You said you have self made tables. How are the columns defined for the fields which needs to include 0? Can you post a screenshot of the table structure? You can also send me the dump of table structure so to check.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 1
Accepted Answer Pending Moderation
Hi there,
Thanx for your speedy answer.

Good question. I am including another screenshot. This timeit is of the database definition. Most of them are 50 character VARCHAR, except for the dates, which are DATETIME (date_added) and DATE (datum) and of course the primary ID,which is an 11 character INT.

At first I had defined that NULL should be allowed ("NULL toestaan";), which meant all the 0's (zeros) were replaced with NULL. So then I changed that to NULL allowed: NO.

Perhaps I should change the data type of the numerical fields to another data type? Can you confirm? If so, which type? INT? DECIMAL? ...?

Thanx,

Thom
Attachments (1)
  1. more than a month ago
  2. RO CSVI
  3. # 2
Accepted Answer Pending Moderation
Hello Thom,
Thank you for posting the screenshot.

I am including another screenshot. This timeit is of the database definition. Most of them are 50 character VARCHAR,

For numeric values by setting the column to VARCHAR you are wasting space.

Perhaps I should change the data type of the numerical fields to another data type? Can you confirm? If so, which type? INT? DECIMAL? ...?

Set the numerical fields to INT(11). You should then be able to import 0.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 3
Accepted Answer Pending Moderation
Hello Thom,
I received your last message little late. Glad to know you figured it :)
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 4
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!