![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have a table with a blob column (that is stored in a sbspace). *Is there a way to do something like: SELECT * FROM <table> WHERE SIZE(<blob_col>) = 12345; I have tried that and also using "LENGTH()" instead of size. *No go. Is there a way to do this using SQL? Thank you. DG |
#3
| |||
| |||
|
|
P.S. *I know that to actually retrieve the data, I need to use one of the provided functions ["lotofile()"] P.P.S. Let me be more clear. I'm trying to identify rows in a table, |
|
On Feb 28, 10:19*am, pretzel <davidegr... (AT) gmail (DOT) com> wrote: I have a table with a blob column (that is stored in a sbspace). *Is there a way to do something like: SELECT * FROM <table> WHERE SIZE(<blob_col>) = 12345; I have tried that and also using "LENGTH()" instead of size. *No go. Is there a way to do this using SQL? Thank you. DG |
#4
| |||
| |||
|
|
On Feb 28, 10:21 am, pretzel <davidegr... (AT) gmail (DOT) com> wrote: P.S. I know that to actually retrieve the data, I need to use one of the provided functions ["lotofile()"] P.P.S. Let me be more clear. I'm trying to identify rows in a table, which rows contain a zero-length blob. Hence, the query would more accurately be described as: SELECT row_pk FROM <table> WHERE SIZE(<blob_column>) = 0; On Feb 28, 10:19 am, pretzel <davidegr... (AT) gmail (DOT) com> wrote: I have a table with a blob column (that is stored in a sbspace). Is there a way to do something like: SELECT * FROM <table> WHERE SIZE(<blob_col>) = 12345; I have tried that and also using "LENGTH()" instead of size. No go. Is there a way to do this using SQL? Thank you. DG _______________________________________________ Informix-list mailing list Informix-list (AT) iiug (DOT) org http://www.iiug.org/mailman/listinfo/informix-list |
#5
| |||
| |||
|
|
IB that you can use the LENGTH() function with a BLOB/CLOB type column, I know you can use it with a TEXT/DATA type column. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) IIUG Board of Directors (a... (AT) iiug (DOT) org) Blog:http://informix-myview.blogspot.com/ |
#6
| |||
| |||
|
|
On Feb 28, 1:23*pm, Art Kagel <art.ka... (AT) gmail (DOT) com> wrote: IB that you can use the LENGTH() function with a BLOB/CLOB type column,I know you can use it with a TEXT/DATA type column. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) IIUG Board of Directors (a... (AT) iiug (DOT) org) Blog:http://informix-myview.blogspot.com/ Thank you, Art. *I always appreciate your posts. I tried the following in dbaccess: "SELECT <row_pk_ FROM <table> WHERE LENGTH(blob)=0;" and got: "674: *Routine (length) can not be resolved." Same thing when trying SIZE(). I see that this has been asked a couple of times in the past 10 years, with no definitive answer, so I suspect Informix does not provide the capability. *Just to be sure, I have opened a tech support case to get the real skinny. Thank you. DG |
#7
| |||
| |||
|
|
On Feb 28, 1:23 pm, Art Kagel <art.ka... (AT) gmail (DOT) com> wrote: IB that you can use the LENGTH() function with a BLOB/CLOB type column, I know you can use it with a TEXT/DATA type column. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) IIUG Board of Directors (a... (AT) iiug (DOT) org) Blog:http://informix-myview.blogspot.com/ Thank you, Art. I always appreciate your posts. I tried the following in dbaccess: "SELECT <row_pk_ FROM <table> WHERE LENGTH(blob)=0;" and got: "674: Routine (length) can not be resolved." Same thing when trying SIZE(). I see that this has been asked a couple of times in the past 10 years, with no definitive answer, so I suspect Informix does not provide the capability. Just to be sure, I have opened a tech support case to get the real skinny. Thank you. DG _______________________________________________ Informix-list mailing list Informix-list (AT) iiug (DOT) org http://www.iiug.org/mailman/listinfo/informix-list |
#8
| |||
| |||
|
|
If you consider a definitive answer the development of the feature I believe you're right... In any case please check this earlier thread: http://www.iiug.org/forums/ids/index.cgi/read/19143 and this article: http://www.ibm.com/developerworks/da...ibrary/techart... I think it will solve your problem... In any case I think we all agree that length(blob) would be better... It's just a question of priorities... Please ask for the feature in your PMR even if this answer solves your problem. As some important person once told me: "we will not implement things that are not asked for... unless we had nothing more to do, which obviously is not the case". The words were not exactly these, I don't remember who is was, but I must agree it makes sense. So, asking for things is a requirement for future complaints ![]() Regards. On Tue, Mar 1, 2011 at 12:06 AM, pretzel <davidegr... (AT) gmail (DOT) com> wrote: On Feb 28, 1:23 pm, Art Kagel <art.ka... (AT) gmail (DOT) com> wrote: IB that you can use the LENGTH() function with a BLOB/CLOB type column, I know you can use it with a TEXT/DATA type column. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) IIUG Board of Directors (a... (AT) iiug (DOT) org) Blog:http://informix-myview.blogspot.com/ Thank you, Art. *I always appreciate your posts. I tried the following in dbaccess: "SELECT <row_pk_ FROM <table> WHERE LENGTH(blob)=0;" and got: "674: *Routine (length) can not be resolved." Same thing when trying SIZE(). I see that this has been asked a couple of times in the past 10 years, with no definitive answer, so I suspect Informix does not provide the capability. *Just to be sure, I have opened a tech support case to get the real skinny. Thank you. DG _______________________________________________ Informix-list mailing list Informix-l... (AT) iiug (DOT) org http://www.iiug.org/mailman/listinfo/informix-list -- Fernando Nunes Portugal http://informix-technology.blogspot.com My email works... but I don't check it frequently... |
#9
| |||
| |||
|
|
--> As some important person once told me: "we will not implement things that --> are not asked for... unless we had nothing more to do, which obviously is --> not the case". obstacle has it... and you can tell that fellow that it is more or less the same discussion as having upper in 9.1 and pre 7.3 Superboer On 1 mrt, 12:51, Fernando Nunes <domusonl... (AT) gmail (DOT) com> wrote: If you consider a definitive answer the development of the feature I believe you're right... In any case please check this earlier thread: http://www.iiug.org/forums/ids/index.cgi/read/19143 and this article: http://www.ibm.com/developerworks/da...ibrary/techart... I think it will solve your problem... In any case I think we all agree that length(blob) would be better... It's just a question of priorities... Please ask for the feature in your PMR even if this answer solves your problem. As some important person once told me: "we will not implement things that are not asked for... unless we had nothing more to do, which obviously is not the case". The words were not exactly these, I don't remember who is was, but I must agree it makes sense. So, asking for things is a requirement for future complaints ![]() Regards. On Tue, Mar 1, 2011 at 12:06 AM, pretzel <davidegr... (AT) gmail (DOT) com> wrote: On Feb 28, 1:23 pm, Art Kagel <art.ka... (AT) gmail (DOT) com> wrote: IB that you can use the LENGTH() function with a BLOB/CLOB type column, I know you can use it with a TEXT/DATA type column. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) IIUG Board of Directors (a... (AT) iiug (DOT) org) Blog:http://informix-myview.blogspot.com/ Thank you, Art. I always appreciate your posts. I tried the following in dbaccess: "SELECT <row_pk_ FROM <table> WHERE LENGTH(blob)=0;" and got: "674: Routine (length) can not be resolved." Same thing when trying SIZE(). I see that this has been asked a couple of times in the past 10 years, with no definitive answer, so I suspect Informix does not provide the capability. Just to be sure, I have opened a tech support case to get the real skinny. Thank you. DG _______________________________________________ Informix-list mailing list Informix-l... (AT) iiug (DOT) org http://www.iiug.org/mailman/listinfo/informix-list -- Fernando Nunes Portugal http://informix-technology.blogspot.com My email works... but I don't check it frequently... _______________________________________________ Informix-list mailing list Informix-list (AT) iiug (DOT) org http://www.iiug.org/mailman/listinfo/informix-list |
#10
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |