10 December 2011

Update OpenQuery v.s. Update LinkedServer.Table

In our recent findings, we have found that the Update statement with LinkedServer could cause database performance issue, which end up giving you a "server is not responding" or timeout error message.

The solution to resolve this issue, is to change the Update LinkedServer.Table statement to Update OpenQuery statement.

This solution is tested and proven workable.

28 April 2011

Crystal Reports Software Download from SAP Business Objects Support

If you do have the same experience, you will notice that it is hard to find Crystal Reports software from the internet. Luckily, we still manage to find the solution from SAP website:

https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/bobj_download/main.htm

18 March 2011

The file 'XXX.aspx' has not been pre-compiled, and cannot be requested.

Development Tool: Microsoft Visual Studio 2008
Project Platform: ASP.NET Web
 
You are trying to browse your ASP.NET web after published it on your web server, but end up Windows giving you this error message in the browser: "The file 'XXX.aspx' has not been pre-compiled, and cannot be requested."
 
The weird part is, you already pre-compile the source codes, rights?
 
Here is the SOLUTION:
 
a). Publish your ASP.NET web project as usual.
 
b). IMPORTANT: Manually copy all of the DLL files into the <Pre-Compiled_Output_Folder>\bin folder. Those DLL files can be Crystal Reports DLL file, if you are using Crystal Reports in your ASP.NET web project.
 
c). Then, publish your ASP.NET web project on your web server as usual.
 
Have fun!

14 March 2011

The table 'TABLE_NAME' could not be found. Error in File REPORT_FILE_PATH: The table could not be found.

Report Tool: Crystal Report from Visual Studio 2008
Database: MySQL Server (any version)
Project Platform: ASP.NET Web

Symptom 1: You can open the Crystal Report in developer's machine successfully.
Symptom 2: You cannot open the Crystal Report in other machines, including other developer's machine.

Error message: The table 'TABLE_NAME' could not be found. Error in File REPORT_FILE_PATH: The table could not be found.

SOLUTION:
  • First, make sure the Crystal Report runtime is installed on the web server.
  • Second, make sure the correct MySQL ODBC Connector is installed on the web server. For example: if you are using MySQL database version 5, then the version of the MySQL ODBC Connector shall be version 5 as well.
  • After that, close all of the internet browsers.
  • Run your web application now, and the error shall be resolved.

08 March 2011

How to find all trigger information in MySQL?

Select
*

From Information_Schema.Triggers
Where trigger_schema = 'YOUR_SCHEMA_NAME'
Order By event_object_table Asc, event_manipulation Asc;

How to find all of the table information in MySQL?

Select
*

From Information_Schema.Tables
Where table_schema = 'YOUR_SCHEMA_NAME';

How to find all of the foreign keys in MySQL?

Select
*
From Information_Schema.Table_Constraints
Where constraint_schema = 'YOUR_SCHEMA_NAME' And
constraint_type = 'FOREIGN KEY'
Order By constraint_name Asc, table_name Asc;

28 February 2011

The 'Microsoft.Jet.OLEDB.4.0' provider is not registered on the local machine

You have encountered the above error message in x64 platform, such as Windows 7?

Well, don't waste your time to find Jet Ole DB updates, it's not related with any update at all.

The solution to fix this issue is to change the target platform of your development from "AnyCPU" to "x86".

a). Go to project's properties.
b). Select the "Compile" tab.
c). Click the "Advanced Compile Options..." button.
d). Select "x86" in "Target CPU:".
e). Please make sure you do the same for Debug mode and Release mode.

18 February 2011

How to retrieve the partitions name of a MySQL table?

Select *
From Information_Schema.Partitions
Where table_schema = 'Schema_Name' And
table_name = 'Table_Name'
Order By partition_name Asc;

How to add partition to MySQL table?

Alter Table Table_Name
Partition By Range (Field_Name)
(
Partition `201101` Values Less Than (201102),
Partition `201102` Values Less Than (201103),
Partition `201103` Values Less Than (201104),
Partition `201104` Values Less Than (201105),
Partition `201105` Values Less Than (201106),
Partition `201106` Values Less Than (201107),
Partition `201107` Values Less Than (201108),
Partition `201108` Values Less Than (201109),
Partition `201109` Values Less Than (201110),
Partition `201110` Values Less Than (201111),
Partition `201111` Values Less Than (201112),
Partition `201112` Values Less Than (201201)
);

The `201101` represents the partition name while the 201102 represents the Less Than value.