Showing posts with label contains. Show all posts
Showing posts with label contains. Show all posts

Friday, March 30, 2012

Korean wording appear as ? in PDF

Can anyone help me ?
My question is :
My report contains some Korean wording. When I export to PDF, the Korean
word appear as ?. Then I export the report in Excel format, there is no
problem in the Korean wording. But when I try to print it, the default page
orientation is 'Landscape' and there is default left and right margin no
matter how I adjust the report size in reporting services.Make sure the font you're using exists on both the server and the client
viewing the PDF.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"May Liu" <MayLiu@.discussions.microsoft.com> wrote in message
news:17D5F204-6D94-4ECA-93A1-E287442C8C5D@.microsoft.com...
> Can anyone help me ?
> My question is :
> My report contains some Korean wording. When I export to PDF, the Korean
> word appear as ?. Then I export the report in Excel format, there is no
> problem in the Korean wording. But when I try to print it, the default
> page
> orientation is 'Landscape' and there is default left and right margin no
> matter how I adjust the report size in reporting services.
>

Monday, March 19, 2012

key/value pair table update query

I'm working with a table that I've created called Config which contains key/value pairs used to get and set site-wide settings. I'm now trying to create a web form which updates the table but I'm not sure how to create the most effective UPDATE query.

Table of course takes this form key | value
----------
config_setting1 | value1
config_setting2 | value2

I'm working with a System.Collections.Specialized.StringDictionary Class object which contains all of the pairs from my webform... anybody have a creative way to build an UPDATE string using this object?

Thanks for any help and suggestions,
ecolner@.yahoo.comI suggest you to create static method to your database class that updates the configuration. The idea is simple.

1) Create parameterized SqlCommand for updates (update conf set value=@.value where setting=@.setting).
2) Start database transaction.
3) Iterate through you string dictionary and on every turn evaluate @.value and @.setting parameters again and then execute the command.
4) If there is errors then roll back database changes, otherwise commit the changes
5) Dispose the update command

Monday, March 12, 2012

KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS

Hi,
My sql table contains duplicate rows & I am trying to delete those but when
i try to delete or when i try to edit & save the duplicate rows i get the
error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
WERE AFFTECTE DBY UPDATE.
how can i delete these dupliacte rows? I cant even make any column a primary
key coz there are duplicates...
Plz help.
Thanks
--
pmudINF: How to Remove Duplicate Rows From a Table
http://support.microsoft.com/default.aspx?scid=kb;en-us;139444
AMB
"pmud" wrote:
> Hi,
> My sql table contains duplicate rows & I am trying to delete those but when
> i try to delete or when i try to edit & save the duplicate rows i get the
> error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
> WERE AFFTECTE DBY UPDATE.
> how can i delete these dupliacte rows? I cant even make any column a primary
> key coz there are duplicates...
> Plz help.
> Thanks
> --
> pmud|||hi Alejandro,
My table doesnt have a primary key...so this procedure doesnt fir here...any
other ways to accompliish this?
Thanks
"Alejandro Mesa" wrote:
> INF: How to Remove Duplicate Rows From a Table
> http://support.microsoft.com/default.aspx?scid=kb;en-us;139444
>
> AMB
>
> "pmud" wrote:
> > Hi,
> >
> > My sql table contains duplicate rows & I am trying to delete those but when
> > i try to delete or when i try to edit & save the duplicate rows i get the
> > error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
> > WERE AFFTECTE DBY UPDATE.
> >
> > how can i delete these dupliacte rows? I cant even make any column a primary
> > key coz there are duplicates...
> >
> > Plz help.
> >
> > Thanks
> > --
> > pmud|||You can alter the table and add a primary key column to it first
ALTER TABLE tablename
ADD id INT IDENTITY (1, 1)
"pmud" wrote:
> hi Alejandro,
> My table doesnt have a primary key...so this procedure doesnt fir here...any
> other ways to accompliish this?
> Thanks
> "Alejandro Mesa" wrote:
> > INF: How to Remove Duplicate Rows From a Table
> > http://support.microsoft.com/default.aspx?scid=kb;en-us;139444
> >
> >
> > AMB
> >
> >
> > "pmud" wrote:
> >
> > > Hi,
> > >
> > > My sql table contains duplicate rows & I am trying to delete those but when
> > > i try to delete or when i try to edit & save the duplicate rows i get the
> > > error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
> > > WERE AFFTECTE DBY UPDATE.
> > >
> > > how can i delete these dupliacte rows? I cant even make any column a primary
> > > key coz there are duplicates...
> > >
> > > Plz help.
> > >
> > > Thanks
> > > --
> > > pmud

KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS

Hi,
My sql table contains duplicate rows & I am trying to delete those but when
i try to delete or when i try to edit & save the duplicate rows i get the
error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
WERE AFFTECTE DBY UPDATE.
how can i delete these dupliacte rows? I cant even make any column a primary
key coz there are duplicates...
Plz help.
Thanks
pmud
INF: How to Remove Duplicate Rows From a Table
http://support.microsoft.com/default...b;en-us;139444
AMB
"pmud" wrote:

> Hi,
> My sql table contains duplicate rows & I am trying to delete those but when
> i try to delete or when i try to edit & save the duplicate rows i get the
> error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
> WERE AFFTECTE DBY UPDATE.
> how can i delete these dupliacte rows? I cant even make any column a primary
> key coz there are duplicates...
> Plz help.
> Thanks
> --
> pmud

KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS

Hi,
My sql table contains duplicate rows & I am trying to delete those but when
i try to delete or when i try to edit & save the duplicate rows i get the
error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROWS
WERE AFFTECTE DBY UPDATE.
how can i delete these dupliacte rows? I cant even make any column a primary
key coz there are duplicates...
Plz help.
Thanks
--
pmudINF: How to Remove Duplicate Rows From a Table
http://support.microsoft.com/defaul...kb;en-us;139444
AMB
"pmud" wrote:

> Hi,
> My sql table contains duplicate rows & I am trying to delete those but whe
n
> i try to delete or when i try to edit & save the duplicate rows i get the
> error ::" KEY COULMN INFORMATION IS INSUFFICIENT OR INCORERCT.TOO MANY ROW
S
> WERE AFFTECTE DBY UPDATE.
> how can i delete these dupliacte rows? I cant even make any column a prima
ry
> key coz there are duplicates...
> Plz help.
> Thanks
> --
> pmud

Friday, March 9, 2012

KeepTogether not working

I have a main report that contains a table. One detail row of that table
calls to a subreport (which also contains a table). When the entire report
displays, if the main report and subreport data will all fit on one page it
will do so, but if not, the main report goes part of the way down a page
(leaving up to 3/4 of the page blank), then breaks to a new page to display
the subreport data. It seems to try and keep the subreport data table
together more than the main report table. I have KeepTogether set to False on
both tables in the main report and the subreport. The way it is now, the
display format is unacceptable. Please offer any ideas.Stotts, I have exactly the same problem as you. Have you found an answer yet?
"stotts" wrote:
> I have a main report that contains a table. One detail row of that table
> calls to a subreport (which also contains a table). When the entire report
> displays, if the main report and subreport data will all fit on one page it
> will do so, but if not, the main report goes part of the way down a page
> (leaving up to 3/4 of the page blank), then breaks to a new page to display
> the subreport data. It seems to try and keep the subreport data table
> together more than the main report table. I have KeepTogether set to False on
> both tables in the main report and the subreport. The way it is now, the
> display format is unacceptable. Please offer any ideas.|||No, not yet. I applied SP1 hoping it would fix it but no luck. Please let me
know if you find anything.
"Pierre" wrote:
> Stotts, I have exactly the same problem as you. Have you found an answer yet?
> "stotts" wrote:
> > I have a main report that contains a table. One detail row of that table
> > calls to a subreport (which also contains a table). When the entire report
> > displays, if the main report and subreport data will all fit on one page it
> > will do so, but if not, the main report goes part of the way down a page
> > (leaving up to 3/4 of the page blank), then breaks to a new page to display
> > the subreport data. It seems to try and keep the subreport data table
> > together more than the main report table. I have KeepTogether set to False on
> > both tables in the main report and the subreport. The way it is now, the
> > display format is unacceptable. Please offer any ideas.

Wednesday, March 7, 2012

Keep Together Possible?

I have a report which contains multiple sub-reports to display different data types that do not relate, but are needed on the same report (the reason for the various sub-reports).

Everything was working fine, until....

The first sub-report is very small, prints maybe 4 inches down the first page. The second sub-report is very large, and now has grown larger than the remainder of the page.

So the second sub-report pushes down and prints of on the 2nd page, leaving most of the first page blank (looks HORRIBLE). I have placed all the sub-reports into a rectangle property, but still do not see anyway to keep the sub-reports together (so they look continuous).

Does anyone know of a work around for this?

Thank you for you help.

T.J.

I'm sorry, there is not a way to override this implicit keep-together on the subreport. The closest you'll get is if you combine the two reports into one.

|||

Thank you for your help.

What is really weird is on the 2nd page of the report, where the 2nd sub-report starts, a 3rd sub-report prints as well.

The 3rd sub-report does print on two pages (where the 2nd sub-report will not do this). And I can find nothing different in the properties of the sub-reports, the main report, or the tables used on the sub-reports.

Very weird. It is like SQL reporting services just picks and chooses when it wants the sub-report to behave correctly.

Hate to have to go back to Crystal, but that might be the only option.

Let me know if you have any other ideas.

Thank you,

T.J.

|||Was the third subreport too large to fit on a single page? If so, it means we can't honor the keep-together and will not try and push it to the next page.|||

Yes, the 3rd sub-report is too large to fit on one page (like the 2nd sub-report), but it breaks out correctly and prints on the 2nd and 3rd page (as expected, the third sub-report starts on the 2nd page, and continues to the 3rd page).

Only the 2nd sub-report forces down to a new page. And I cannot find anything different in these sub-reports at all.

Very strange deal.

Thank you for your help. If worse comes to worse, I can build it in Crystal and run it for the users and send them a .pdf.

|||

Printing it out and looking closely, it appears the report footer in the 2nd sub-form just barely does not fit on the first page.

I cannot find any properties to control this, but maybe the glitch is caused by the report forcing the page footer to print on the same page as the rest of the sub-report.

I then expanded the vertical white space in my 2nd sub-report, and the overall report printed as I had hoped (the 2nd sub-report correctly starts on the first page). The bad thing is now my 2nd sub-report has vertical white space on each record that I did not need added.

A start though.

Any thoughts?

I

|||

Just wanted to follow up, for other report developer's sake.

Maybe I caught a glitch with SQL reporting services, in which the footer forces the entire sub-form to move to the next page? Maybe this is already known?

Any thoughts?

Thank you!

T.J.

Friday, February 24, 2012

Keep records that contain certain attributes

Have a report that I want to keep certain attributes and as long as the report contains this certain attribute, bring all other attributes with it. Better with an example. In this report I am specifically looking for attribute "Alcohol", if I find this attribute I want to include all others that fit with this record's Primary Key which could include, "Drugs","Arson","Vandalism", etc. Problem is when I try to use a paramater or filter I get the "Alcohol" Attribute but not the "Drugs","Arson","Vandalism", etc. Conversely since I dont have any filter/paramater set I get everything even if it does not include "Alcohol"

suggestions?

thansk in advance

km

Hi km

I am having a bit of trouble understanding what data you are working with.
Once this is clear perhaps I can help.
Does your data-set look like the following?

Primary Key | Problem
-
1 Drugs
1 Alcohol
1 Vandalism
2 Theft
2 Drugs

And you want to display all rows with PrimaryKey = 1 (since it includes alcohol), but not any rows with Primary Key 2?

If that is the case it will definitely be easiest to do this in you query itself, not in the report.
Something like:

Select * From Table WHERE PrimaryKey IN
(SELECT PrimaryKey From Table WHERE Problem = 'Alcohol'

Cheers
Mark
|||

thanks Mark

Yes this is similiar to my data found out that there is a unique key for each atttribute so all is resolved

thanks for your response

km

Keep records that contain certain attributes

Have a report that I want to keep certain attributes and as long as the report contains this certain attribute, bring all other attributes with it. Better with an example. In this report I am specifically looking for attribute "Alcohol", if I find this attribute I want to include all others that fit with this record's Primary Key which could include, "Drugs","Arson","Vandalism", etc. Problem is when I try to use a paramater or filter I get the "Alcohol" Attribute but not the "Drugs","Arson","Vandalism", etc. Conversely since I dont have any filter/paramater set I get everything even if it does not include "Alcohol"

suggestions?

thansk in advance

km

Hi km

I am having a bit of trouble understanding what data you are working with.
Once this is clear perhaps I can help.
Does your data-set look like the following?

Primary Key | Problem
-
1 Drugs
1 Alcohol
1 Vandalism
2 Theft
2 Drugs

And you want to display all rows with PrimaryKey = 1 (since it includes alcohol), but not any rows with Primary Key 2?

If that is the case it will definitely be easiest to do this in you query itself, not in the report.
Something like:

Select * From Table WHERE PrimaryKey IN
(SELECT PrimaryKey From Table WHERE Problem = 'Alcohol'

Cheers
Mark
|||

thanks Mark

Yes this is similiar to my data found out that there is a unique key for each atttribute so all is resolved

thanks for your response

km