AdWords is now Google Ads. Our new name reflects the full range of advertising options we offer across Search, Display, YouTube, and more. Learn more

Data Studio
2.5K members online now
2.5K members online now
Ask questions about Data Studio
Guide Me
star_border
Reply

CSV table references column position 24, but line starting at position:0 contains only 24 columns.

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Seem to be having an issue with datastudio and BQ, I have a feeling it's got something to do with the schema. 

 

Here's what the dataset looks like;

 

monthprojectnumberproductprojecttitleourcontactquotestatusesservicedepartmentdescriptionpricequotedquantityquotedratecardtotalquoteddiscounttotalquotediscountbookedquantitybookedratecardbookeddiscountbookedquantityinsurveybookedratecardinsurveybookedvalueinsurveyribbonquotediscountribbonnonextrasforecastdiscountfacilityquotediscountfacilityforecastdiscount
2014010158599Woolitejob1myname('Confirmed', 'Completed')COMB1(Combustion)0000010005005099  
          0000  0       

 

If I autodetect the schema it thinks the last two of "facilitydiscountquote" and "facilityforcastdiscount" are strings. 

 

If I manually import the schema and say it's an integer I get the following error;

 

 

Failure details:
- gs://ceta-data/ytdboards.csv: CSV table references column position
24, but line starting at position:0 contains only 24 columns.

Here's my schema file;

 

[
  {"month": "month", "type": "integer", "mode": "nullable"},
  {"projectnumber": "projectnumber", "type": "integer", "mode": "nullable"},
  {"product": "product", "type": "string", "mode": "nullable"}
  {"projecttitle": "projecttitle", "type": "string", "mode": "nullable"}
  {"ourcontact": "ourcontact", "type": "string", "mode": "nullable"}
  {"quotestatuses": "quotestatuses", "type": "string", "mode": "nullable"}
  {"service": "service", "type": "string", "mode": "nullable"}
  {"department": "department", "type": "string", "mode": "nullable"}
  {"description": "description", "type": "string", "mode": "nullable"}
  {"price": "price", "type": "integer", "mode": "nullable"}
  {"quotedquantity": "quotedquantity", "type": "float", "mode": "nullable"}
  {"quotedratecardtotal": "quotedratecardtotal", "type": "integer", "mode": "nullable"}
  {"quoteddiscounttotal": "quoteddiscounttotal", "type": "integer", "mode": "nullable"}
  {"quotediscount": "quotediscount", "type": "string", "mode": "nullable"}
  {"bookedquantity": "bookedquantity", "type": "float", "mode": "nullable"}
  {"bookedratecard": "bookedratecard", "type": "integer", "mode": "nullable"}
  {"bookeddiscount": "bookeddiscount", "type": "integer", "mode": "nullable"}
  {"bookedquantityinsurvey": "bookedquantityinsurvey", "type": "integer", "mode": "nullable"}
  {"bookedratecardinsurvey": "bookedratecardinsurvey", "type": "integer", "mode": "nullable"}
  {"bookedvalueinsurvey": "bookedvalueinsurvey", "type": "integer", "mode": "nullable"}
  {"ribbonquotediscount": "ribbonquotediscount", "type": "integer", "mode": "nullable"}
  {"ribbonnonextrasforecastdiscount": "ribbonnonextrasforecastdiscount", "type": "integer", "mode": "nullable"}
  {"facilityquotediscount": "facilityquotediscount", "type": "integer", "mode": "nullable"}
  {"facilityforecastdiscount": "facilityforecastdiscount", "type": "integer", "mode": "nullable"}
  {"string_field_24": "string_field_24", "type": "string", "mode": "nullable"}
]

 

Anyone have any ideas? Getting stuck here. (Also no idea how to x-post to big query)

 

CSV table references column position 24, but line starting at position:0 contains only 24 columns.

Participant ✭ ✭ ☆
# 2
Participant ✭ ✭ ☆

Are you loading a csv directly to DS? How big is your data? If it's not enormous, you could put it in Google Sheets instead, then link that up. 

CSV table references column position 24, but line starting at position:0 contains only 24 columns.

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭

Not that large but a decent chunk. I've figured it out I think, that column contains integers and then a string,"NULL" which explains it Smiley Happy