From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Import Access DB to SQL Server

Solved!
Go to solution

I'm trying to setup a SQL-Server Database.

Currently i'm using Access, and my own Scheme which is very close to the "Generic Recordset".

I've tried several things.

* Strip my .mdb to contain only tables but no data.

* Import this to SQL Server.

** Import complete .mdb database including data.

My tablenames in SQL Server always gets the prefix "dbo". That means they are using a "dbo" scheme - right ?

 

I can export my Scheme (.ini) from TestStand, but how do I get that into SQL-SERVER ?

 

Currently I get the error below:  (is this the result of not having the correct scheme in place ?)

 

An error occurred calling 'LogMultipleResults' in 'ITSDBLog' of 'zNI TestStand Database Logging'

An error occurred executing a statement.

Statement: UUT_RESULT.

Description: Cannot insert the value NULL into column 'ID', table 'PTA_DR2_COMMON.dbo.UUT_RESULT'; column does not allow nulls. INSERT fails.

Number: -2147217873

NativeError: 515

SQLState: 23000

Reported by: Microsoft SQL Server Native Client 11.0Description: The statement has been terminated.

Number: -2147217873

NativeError: 3621

SQLState: 01000

Reported by: Microsoft SQL Server Native Client 11.0Description: Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.

Number: -2147217887

NativeError: 0

SQLState: 01000

Reported by: Microsoft SQL Server Native Client 11.0

 

 

Under the "data link property" in TestStand I set up to use a "Specific User Name and Password" which is set up in SQL Server.

I choose to save the "Password".

Test connection is OK.

If I close the window, but reopen it right after,  the password properties are gone... that means it's not saved !   Why ?

If I use NT integrated Security, the access to the database is working.

0 Kudos
Message 1 of 2
(2,908 Views)
Solution
Accepted by topic author NikolajEgeskovOstergaard

I found a "Solution" by exporting each table one by one from Access instead of Importing on SQL Server.

Now it seems to be OK 

Message 2 of 2
(2,866 Views)