I have an array field in the SQL database I am using. In crystal when I attempt to use this field is is read as a picture field. Is there a fix for this?
Thank you.
I've never heard of a ARRAY type of field, however there are binary types which allow for arrays.
Please use proper technical terms, and please clarify that SQL database means SQL Server, a SQL database would mena a database which supports the SQL language, which is most.
In general please supply:
Crystal version
Database/connectivity type
Example data
Expected output
You can right click the field in Crystal and select Browse data to get it's data type.
I would guess that the developers have stored an array within a binary field. When geekzzz decide to be clever, they generally aren't
I was told it was an array field: it's contained within an array called labor in probsummary, it should be the third value in the array. It's laid out as follows:
labor {labor.date,operator,hours.worked,li.contract.id, labor.gl.number}
We are using Crystal Reports 11 and the data is on a SQL Server I am connected to using a ODBC(RDO)connection. The data base guy stated he thinks Crystal is reading it as a binary large object or a blob file.
What I am attempting to do is pull the third value (hours.worked) from this "array" field. the majority of the time if I am tolde it is an "array" field it displays in Crystal as a memo data type, this field is displaying picture for the data type.
Thank you
I would suggest that they expose the data within a View to resolve this concern.
What I believe they are doing is saving data within a binary as an array, which probably seems clever for some reason, however you're discovering that it doesn't lend itself to other tools.
You might also try using a SQL Expression to CAST or CONVERT the data into a more usable format. Check with the dba on the syntax for doing so.
What version of SQL Server are you using? Arrays *might* be supported in the next version (which isn't slated for release for some time). Unless you're using a beta version, it isn't an array. It's likely stored as an IMAGE data type, in which case, Crystal won't be able to read it. There are SQL Server functions that can read that type of data, but I've only used them sparingly.
Perhaps you or "the database guy" can read more about how to get data out of IMAGE, TEXT and NTEXT datatypes in the SQL Server help files (aka SQL Server Books Online). If you look under the Contents tab, the path is:
Accessing and Changing Relational Data
Advanced Query Concepts
Managing ntext, text, or image
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.