Solved

query and display compressed data?

Posted on 2012-04-01
3
277 Views
Last Modified: 2012-04-05
i have a table in a sql server 2008 server that has compressed data in several columns

how do i query and view/display that data?

for instance,

select orderno, shipdate, otherdata from orders
where shipdate > '20111231'

the orderno and shipdate are not compressed and display fine.....  the data in the otherdata column is compressed and  either doesnt display at all (mgmt studio), or displays 'junk' characters (in some other query tools)
0
Comment
Question by:jimwarrenus
3 Comments
 
LVL 25

Assisted Solution

by:jogos
jogos earned 250 total points
ID: 37793738
Is it compressed by SQL Server?

Can you post the table definition.
0
 
LVL 15

Accepted Solution

by:
Deepak Chauhan earned 250 total points
ID: 37793801
Hi Dear...

            please check select permission on this table it may be possible u dont have permission on 'otherdata column of this table.
                I don't think data compression is the reason of doesn't showing 'otherdata' column as i understand data compression can be two type row level or page level if two column is showing from this table which is also part of complete row and if we are talking about page level then page is also stored data in row format.

you can test this with (select * from order) if you dont have full select permission then query will through an error....
0
 

Author Closing Comment

by:jimwarrenus
ID: 37812982
i finally heard from the developer and turns out they also refer to it as "packed"....<br />this solved the problem:<br /><br />SELECT CAST(CAST(SUBSTRING(BIGDAT<wbr />A,1,4)AS VARBINARY) AS BIGINT)<br />FROM PROCESSING
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question