Showing posts with label rows. Show all posts
Showing posts with label rows. Show all posts

Tuesday, March 27, 2012

Boolean - Expanded/Collapsed

I have created a matrix where I have booleans on the rows and columns. They are initially in the collapsed state. For reporting purposes, I would like the initial state to to be expanded or at list a quick fix to quickly convert the collapsed booleans to expanded booleans.

I have navigated to the Layout tab and right-clicked the fields that are tied to the boolean and then clicked on the properties. This bring sup the Textbox Properties. From here, I click on the Visibility tab. At the bottom of the textbox is a section "Initial appearance of the toggle image for this report item:". The default choice is marked as collapsed (+). One would logically think that you you would have to do then is select the expanded (-). choice. Well, when I do this, all it simply does is chance the icon from a '+' to a '-' and the fields are still shown as collapsed.

Any ideas on what I need to do?

ttt|||

If I am understand it right, what you will have to do is

1. Select the Entire row and go to the properties

2. Go to "Visibility " --> "Hidden" set this to False if you want this to be expanded or to true.

|||

Expand/Collapse

1) Create a parameter and name it something like "Expand" and name the Prompt "Expand All" or whatever you choose

2) Set the parameter to Boolean

3) Set the default value Non-queried to "True"

4) Click on OK

5) Select properties for the control box that is supporting the +- like you said below

a)"I have navigated to the Layout tab and right-clicked the fields that are tied to the boolean"

6) Click on Visibility

7)Select Expression: and insert this "=Iif(Parameters!Expand.Value = True, True, False)"

8)Click OK

9)Select properties for the matrix and select "Groups"

10) Select the group where you have the "Visibility can be toggled by another report item"

11) Select Expression: and insert this "=Iif(Parameters!Expand.Value = True, False, True)"

12)Click on OK

13)Click on OK

Give it a shot. . .

When you change the parameter, you will need to reselect the view report button.

|||

This post is in response to Techquest ...

If I go to the Layout View, select the row, then right-click and select Properties, I do not see an option for "Visibility". However, if I select just one field, then right-click and select Properties, I do see an option for "Visibility". I have tried to change every single field by doing this (and if I remember correctly -- because it was last week) and it still does not do what I am looking for.

|||

Hi JCU1343,

Your right, you do not want to select the entire row, but instead you want to select just one field in the table. That's where you will find the Visibility control. It should be the field where the "+" and "-" sign will appear. When you insert the code: "=Iif(Parameters!Expand.Value = True, True, False)" in the Expression at the bottom of the "Visibility" tab, this gives control at the parameter level to change the "+" to "-" and back again. Then having selected the properties of the group in your table and selecting the "Visibility" tab for the group you should insert "=Iif(Parameters!Expand.Value = True, False, True)" which will expand/collapse the entire group depending on which choice you selected and you should also see the "checked" field here indicating the "Visibilty can be toggled by another report item". Every time you select the parameter you have to re-run the report.

Hope this helps. . .

Don't forget this feature depends on a parameter, and I know it works because I've used it on at least 8 reports for my company.

|||

FLHTCUI - Arizona Harley Rider:

Thank you so much for your posts (especially the first post). That is exactly what I was looking for/wanted. I truly appreciate it. You are a big help!

Can I direct you over to another post that I created that no one has been able to provide an answer to? It can be found here: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1852697&SiteID=1

Wednesday, March 7, 2012

Block row from been updated

I need to block some rows from being updated using mssql 2000.
this is because some users are changing data after the product has been
factured.
The VB program does not let any body to change the data but some advanced
users have done it directly to the database.
If some one can help me I will be very thankful
Regards, LinaWhy do those "advanced users" even have access to the database?
They should not.|||Given that you need to solve the problem as it exists, the simplest approach
would be to put a trigger on the table that checks to see if one of the
"non-alterable" records is being updated and roll back the transaction. You
might also want to log who is updating the row for future personnel related
actions.
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
<Octavius@.gmail.com> wrote in message
news:1135822838.009333.252160@.g14g2000cwa.googlegroups.com...
> Why do those "advanced users" even have access to the database?
> They should not.
>|||Thanks a lot, Lina
"Roger Wolter[MSFT]" wrote:

> Given that you need to solve the problem as it exists, the simplest approa
ch
> would be to put a trigger on the table that checks to see if one of the
> "non-alterable" records is being updated and roll back the transaction. Y
ou
> might also want to log who is updating the row for future personnel relate
d
> actions.
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
.
> Use of included script samples are subject to the terms specified at
> http://www.microsoft.com/info/cpyright.htm
> <Octavius@.gmail.com> wrote in message
> news:1135822838.009333.252160@.g14g2000cwa.googlegroups.com...
>
>|||You could try using the APP_NAME function. Run SQL Query Analyzer, and
execute sp_who2 while some users are connected. Look under the ProgramName
column to see what the name of your application is as it appears to the
server.
Then put some logic into your stored procedures, or into an INSTEAD OF
trigger on your table(s)
IF APP_NAME() <> 'YourApp'
--Sorry Charlie!
If your application doesn't report a ProgramName, but the "advanced users"
are using something like Access or a command line tool that does report a
ProgramName, you could block it with something like
IF APP_NAME() IN ('Microsoft Access', 'osql')
"Lina Manjarres" wrote:

> I need to block some rows from being updated using mssql 2000.
> this is because some users are changing data after the product has been
> factured.
> The VB program does not let any body to change the data but some advanced
> users have done it directly to the database.
> If some one can help me I will be very thankful
> Regards, Lina|||Thanks a lot Mark
I used this:
IF EXISTS(SELECT * FROM inserted WHERE facturado_Cliente = 1)
Begin
ROLLBACK TRAN
End
and i had a problem wit it. After the facturado_Cliente where changed to 0
again, it did not let me change the row any more. I mean, I couldn't make it
1 again, it allways rolled back.
So I will try what you suggest me, because it sound perfect. Is it posible
to do so, but with the HostName?
Thanks a lot, Lina
"Mark Williams" wrote:
> You could try using the APP_NAME function. Run SQL Query Analyzer, and
> execute sp_who2 while some users are connected. Look under the ProgramName
> column to see what the name of your application is as it appears to the
> server.
> Then put some logic into your stored procedures, or into an INSTEAD OF
> trigger on your table(s)
> IF APP_NAME() <> 'YourApp'
> --Sorry Charlie!
> If your application doesn't report a ProgramName, but the "advanced users"
> are using something like Access or a command line tool that does report a
> ProgramName, you could block it with something like
> IF APP_NAME() IN ('Microsoft Access', 'osql')
> "Lina Manjarres" wrote:
>|||The HOST_NAME() function will return the hostname of the system associated
with the connection, which you could use in a WHERE clause, but it is
probably not a good idea. You would have to block individual machine names,
and all someone would have to do in order to defeat your filter is
move to another machine , or
change their machine name
It would probably work out better to put in a filter condition based on
APP_NAME() . Does your application show a ProgramName value when you run
sp_who2 ? If it does, filter the updates based on the ProgramName.
"Lina Manjarres" wrote:
> Thanks a lot Mark
> I used this:
> IF EXISTS(SELECT * FROM inserted WHERE facturado_Cliente = 1)
> Begin
> ROLLBACK TRAN
> End
> and i had a problem wit it. After the facturado_Cliente where changed to 0
> again, it did not let me change the row any more. I mean, I couldn't make
it
> 1 again, it allways rolled back.
> So I will try what you suggest me, because it sound perfect. Is it posible
> to do so, but with the HostName?
> Thanks a lot, Lina
> "Mark Williams" wrote:
>|||Thanks a lot Mark.
One more question.
What happend when I have several SQL replicating. Is there any problem wit i
t?
"Mark Williams" wrote:
> The HOST_NAME() function will return the hostname of the system associated
> with the connection, which you could use in a WHERE clause, but it is
> probably not a good idea. You would have to block individual machine names
,
> and all someone would have to do in order to defeat your filter is
> move to another machine , or
> change their machine name
> It would probably work out better to put in a filter condition based on
> APP_NAME() . Does your application show a ProgramName value when you run
> sp_who2 ? If it does, filter the updates based on the ProgramName.
> "Lina Manjarres" wrote:
>|||If the table is involved in replication, you can place the application
checking logic into an INSTEAD OF trigger, and create the trigger with the
NOT FOR REPLICATION option. This will prevent the trigger from firing when a
replication operation modifies the table. See books online for more details.
If you posted to this forum through TechNet, and you found my answers
helpful, please mark them as answers. Thanks!
"Lina Manjarres" wrote:
> Thanks a lot Mark.
> One more question.
> What happend when I have several SQL replicating. Is there any problem wit
it?
> "Mark Williams" wrote:
>|||Dear Mark
I am using this:
AFTER UPDATE NOT FOR REPLICATION
Is it ok or do I have to use Instead of?
Thanks a lot, Lina
"Mark Williams" wrote:
> If the table is involved in replication, you can place the application
> checking logic into an INSTEAD OF trigger, and create the trigger with the
> NOT FOR REPLICATION option. This will prevent the trigger from firing when
a
> replication operation modifies the table. See books online for more detail
s.
> --
> If you posted to this forum through TechNet, and you found my answers
> helpful, please mark them as answers. Thanks!
>
> "Lina Manjarres" wrote:
>

Saturday, February 25, 2012

BLOBs and the 8K rows

Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
they more like images and text and not restricted to 8KB?
ThanksDepend how is setup the table's option "text in row" for this specific table
.
See "sp_tableoption" in BOL for more info.
AMB
"Robert Kinesta" wrote:

> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks|||Hi
BLOB is a synonym for Image and Text data types.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks|||BLOBs (image and text) are not restricted by the 8KB row size. A BLOB could
be as big as 2Gb. It is stored to multiple 8KB pages and managered by a
btree-like structure.
Stephen Jiang
Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks

BLOBs and the 8K rows

Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
they more like images and text and not restricted to 8KB?
Thanks
Depend how is setup the table's option "text in row" for this specific table.
See "sp_tableoption" in BOL for more info.
AMB
"Robert Kinesta" wrote:

> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks
|||Hi
BLOB is a synonym for Image and Text data types.
Regards
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks
|||BLOBs (image and text) are not restricted by the 8KB row size. A BLOB could
be as big as 2Gb. It is stored to multiple 8KB pages and managered by a
btree-like structure.
Stephen Jiang
Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks

BLOBs and the 8K rows

Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
they more like images and text and not restricted to 8KB?
ThanksDepend how is setup the table's option "text in row" for this specific table.
See "sp_tableoption" in BOL for more info.
AMB
"Robert Kinesta" wrote:
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks|||Hi
BLOB is a synonym for Image and Text data types.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks|||BLOBs (image and text) are not restricted by the 8KB row size. A BLOB could
be as big as 2Gb. It is stored to multiple 8KB pages and managered by a
btree-like structure.
--
Stephen Jiang
Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Robert Kinesta" <RobertKinesta@.discussions.microsoft.com> wrote in message
news:BFD95D29-B5A7-4DB1-BCB6-E26FAFD8CF7C@.microsoft.com...
> Does anyone know if BLOBs are restricted by the 8KB row size rule? Or are
> they more like images and text and not restricted to 8KB?
> Thanks

Friday, February 24, 2012

Blank values Replicating to Oracle

Replicating from SQL Server 2005 to Oracle 9i Release 2. The source table has NOT NULL specified for all columns. The table contains multiple rows with blank values in one of the NOT NULL columns. When I attempt to replicate this table to Oracle, I'm unable to replicate the rows containing the blank values.

I've followed the directions in the Oracle Subscribers page in Books Online: http://msdn2.microsoft.com/en-us/library/ms151738.aspx

Modify the generated create table script, removing the NOT NULL attribute from any character columns that may have associated empty strings, and supply the modified script as a custom create script for the article using the @.creation_script parameter of sp_addarticle

Here is the segment of the Publication Script referencing sp_addarticle:

exec sp_addarticle
@.publication = N'mike_hayes_test_replication2',
@.article = N'mike_hayes_test_replication',
@.source_owner = N'bmssa',
@.source_object = N'mike_hayes_test_replication',
@.type = N'logbased',
@.description = N'',
@.creation_script = 'CREATE TABLE [bmssa].[mike_hayes_test_replication2]( [EXCELCOLUMN] [int] NULL, [TABLENAME] [varchar](40) NULL, [FIELDNUM] [int] NULL , [REFTABLEID] [int] NULL , [MODULETYPE] [int] NULL , [DATAAREAID] [varchar](3) NULL, [RECVERSION] [int] NULL, [RECID] [int] NULL, [BRAND] [varchar](20) NULL )',
@.pre_creation_cmd = N'drop',
@.schema_option = 0x00,
@.identityrangemanagementoption = N'manual',
@.destination_table = N'mike_hayes_test_replication2',
@.destination_owner = N'bmssa',
@.vertical_partition = N'false'
GO

I added the @.creation_script value, and changed the schema_option to 0x00.

The problem is that when replication occurs, the table that is created has NOT NULL specified for all columns. I expected that the @.creation_script would be executed, (as per the instructions), but that doesn't appear to be the case.

Any ideas?

Thanks for your help.

Mike Hayes

Hi Mike, you should specify the path to the file containing the create table statement for the @.creation_script parameter instead of just the "create table" statement.

Hope that helps,

-Raymond

|||Thanks for the reply. So this should be an Oracle script? Should I refer to it on the server (i.e. c:\scripts, where c:\ refers to the SQL Server drive)?

Thanks,

Mike Hayes|||

The syntax can arguably be anything compatible with Oracle although the safer thing to do is to just modify what the snapshot agent would have generated otherwise. The path should be something that is accessible(and\or relative) to the snapshot agent process since your file will then be copied by the snapshot agent to the snapshot folder. I am actually a bit surprised that the snapshot agent didn't die a horrible death trying to copy the "weird path" so something may be amiss here.

Come to think of it, would it be easier to just modify the script generated by the snapshot agent?

-Raymond

Sunday, February 19, 2012

Blank rows on report

Hello,
My report seems to be generrating a randon number of rows per page. Some
pages have only one row, others three and some blank. this does not appear
to correspond to group breaks. Has anyone else seen this? Is there a way to
make the report rows follow immediately one after another?
Thanks.HI jo st charles,
i encountered the same problem because of the improper groupings onli.
u can check the same.
check out the detail cell u can find some more.if u can give out some more
info
i will help u out.
cheers
drupa

Blank rows in Export To Excel

Hi All,

Few days back we faced a problem when we were doing an Export to Excel of a report which was using sub-reports. After going thro. the knowledge base articles we came to know that SSRS currently doesn't suppot this option, an alternate is to use use List instead of tables, so we used List and did all the formatting with the list and the data was displayed correctly and it was Exporting to Excel also properly. But now we found out that after doing an Export to Excel, the Excel File is leaving blank rows between the data (i.e.,) If the report consists of two rows, then it displays the first row in the 10th row of excel and the second row in the 12th row of excel. The 11th row is blank and it appears as a small blank row between 10 and 12. The actual problem because of this is we are not able to do Auto filter in Excel, because Excel by default considers the values only until it encounters a blank row when we are doing auto filter. So is there a way to avoid this blank row while exporting to Excel, we have tried to remove the borders and all other stuffs but nothing seems to work. Have anyone encountered the same problem or is there any work around for this problem. Thanks in advance.

Have you tried removing padding for all the textboxes in your row in the list?

|||

We have removed all the padding for the textboxes but still the same problem is coming. The moment we add the subreport this is happening, until then it is fine.

Note: The sub reports are placed in a list inside another list.

|||

Maybe your subreport is still visible but with no data. Try hiding it based on some condition.

Also make sure that you dont have any gap vertically between all objects (textboxes, list, subreport etc) in your designer.

Shyam

Blank Row comming out from Excel Source?

Hi,

I use an excel datasource to populate some simple dimensions, but when i extract the excel file i get alot of blank rows from the excel files...

How can i overcome this issue? Is this normal?

I never had problems like this using DTS in the 2000 version

Best Regards,

Luis Sim?es

Perhaps, your Excel file has empty rows in the spreadsheet.

You should not see any difference when using DTS or SSIS wizard if the same source file is used.

Thanks.

|||

How do i know there are empty rows?