Showing posts with label documentation. Show all posts
Showing posts with label documentation. Show all posts

Saturday, February 25, 2012

CAB Files

Can anyone Please point me to a place that I can find some documentation on what the sql.ppc.wce5.armv4i.CAB does?

I basically need to know which files are being placed in the handset by deplyoing the CAB file.

Thanks,

Farnaz

The cab file contents are documented here: http://www.microsoft.com/sql/editions/sqlmobile/installsdk.mspx

Friday, February 24, 2012

C# code for saving data from excel to mssql database

Hello everyone,

I am trying to find some code or documentation that I can use to create a web page that will save data from an excel file to a mssql databaseAfter you save the Excel file, open it and read records from it using this article:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;316934

And then use normal ADO.NET procedures to update the SQL Server database.|||Thanks a lot I will take a look at this article now|||Thanks for the tip all worked well on my local machine but when I uploaded it to an external server and tested I keep getting this error:

System.Data.OleDb.OleDbException: The Microsoft Jet database engine cannot open the file ''. It is already opened exclusively by another user, or you need permission to view its data. at System.Data.OleDb.OleDbConnection.ProcessResults(Int32 hr) at System.Data.OleDb.OleDbConnection.InitializeProvider() at System.Data.OleDb.OleDbConnection.Open() at summitPortal.controls.bulk.insertdata(String sSheetPath) at summitPortal.controls.bulk.ImageButton1_Click(Object sender, ImageClickEventArgs e) at System.Web.UI.WebControls.ImageButton.OnClick(ImageClickEventArgs e) at System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain()

The file is definately not in use because I even restarted the computer and tried again.
I also checked the permissions and they seem to be ok.

Any ideas anyone?|||I'm not so sure about this but did you check yourExcel file is read-only or not? sometimes I get some error when I open read-only files. anyway, I will try what you're doin right now.|||Check out this Microsoft troubleshooting article:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;q306269

Tuesday, February 14, 2012

But the documentation is NOT correct

The documentation says

ISNUMERIC returns 1 when the input expression evaluates to a valid
integer, floating point number, money or decimal type; otherwise it
returns 0. A return value of 1 guarantees that expression can be
converted to one of these numeric types.

(Cut and pasted from books online)

Yet the following, one of many, example shows this is not true.

select isnumeric(char(9))
select convert(int, char(9))

----
1

(1 row(s) affected)

Server: Msg 245, Level 16, State 1, Line 2
Syntax error converting the varchar value '' to a column of data type
int.

So, besides filtering every possible invalid character, how do you
convert dirty values without error. I am not concerned that I may loose
possibly valid values or convert suspect strings to 0 (zero). I just
want to run without raising an errorBooks Online is quite correct here, it just could be a bit clearer. The
significant word in the paragraph you posted is "or". ISNUMERIC returns
1 if the data is convertible to ANY of the datatypes listed. Try the
following, which will work:

SELECT CONVERT(MONEY, CHAR(9))

If you just want to convert positive integers then you can use LIKE to
determine whether a string contains only numerics:

SELECT CAST(col AS INTEGER)
FROM YourTable
WHERE col NOT LIKE '%[^0-9]%'

--
David Portas
SQL Server MVP
--|||By inference then CONVERT(MONEY, x) is the most 'tolerant' conversion.
Strings containing only numerics is also elegant.

Thanks for the tip|||(bilbo.baggins@.freesurf.ch) writes:
> By inference then CONVERT(MONEY, x) is the most 'tolerant' conversion.

Not necessarily:

SELECT convert(money, '1E1')

bombs. But isnumeric() returns 1.

isnumeric is a useless function.

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp

Friday, February 10, 2012

Bulk-Logged Recovery - Data Loss?

Folks,
Version: SQL Server 2000 SP3
I've been trying to determine from the documentation if there is any
potential for data loss while a database is in Bulk-Logged Recovery Mode
(BLRM), assuming that the server does not experience anything out of the norm.
Just prior to a DBREINDEX on several tables during minimal user activity, I
plan on putting the database into BLRM. I will return it to Full Recovery
Mode (FRM) upon completion of the reorg. My concern is that if there is a
user transaction during this DBREINDEX will it be logged, and therefore
recoverable? I'm thinking yes. Would just like confirmation.
Much obliged.
--
Scott H.Scott H.,
If the backup of the log include bulk-logged operations, then you will not
be able to restore to a point-in-time within that log backup; you can restore
only the whole log backup.
If something happend during the bulk operation and you need to backup the
log, then the data files that contain the bulk-logged transaction should be
accesible. If any affected data file is inaccessible, the transaction log
cannot be backed up and all operations committed in that log are lost.
Backup Under the Bulk-Logged Recovery Model
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/c6bce51b-f401-408e-a1d6-f53866cd7351.htm
AMB
"Scott H." wrote:
> Folks,
> Version: SQL Server 2000 SP3
> I've been trying to determine from the documentation if there is any
> potential for data loss while a database is in Bulk-Logged Recovery Mode
> (BLRM), assuming that the server does not experience anything out of the norm.
> Just prior to a DBREINDEX on several tables during minimal user activity, I
> plan on putting the database into BLRM. I will return it to Full Recovery
> Mode (FRM) upon completion of the reorg. My concern is that if there is a
> user transaction during this DBREINDEX will it be logged, and therefore
> recoverable? I'm thinking yes. Would just like confirmation.
> Much obliged.
> --
> Scott H.